# It Inserts by getting all fields values directly from table and Insert that value like a new record in that table. It selects that …
Read MoreArticle
Sql – how to Join two table in php
# Join Two Table data in Sql using php // used for select data $join_sel = “p.id,p.approved,pc.cid”; //Use for select table & join $join_frm = …
Read Morephp- How to get image height and width
# LIST IMAGE INFO list($width, $height, $type, $attr) = getimagesize($_FILES[“img”][‘tmp_name’]); echo $width; // shows width echo $height; // shows height
Read MorePhp- Show any text only 100 letters
## In a particular div by using this we can show only 100 letters and then … in php by removing tags. $product_description = html_entity_decode($product_description); …
Read MorePhp: How to show star rating
## Showing Rating in Php using star & blank rating $ProductId = 1; $product_rating_qu = mysql_query(“select avg(rating) as star_rate from ratings where ratedto='” . $ProductId …
Read MoreJavaScript: show confirm alert on click
## By calling this function on form submit, will confirm for submit <script> function confirmme() { var r = confirm(“Want To Submit this..??”); if(r) …
Read MoreChange uploading image name in php
if ($_FILES[‘img’][‘name’] != “”) { $allowed_ext = array(“jpg”, “jpeg”, “png”, “gif”); $extension = explode(‘.’, $_FILES[“img”][“name”]); $ext = strtolower(end($extension)); …
Read Moresearch in php
## Here multiple word search is tried.. Its working.. $data = array(); $data[‘search_list’] = “”; $data[‘total_search’] = “”; $data[‘search_on’] = “”; $data[‘search_words’] = “”; $_searchfield …
Read MoreCheck the field value Number or not in Javascript
<script type=”text/javascript”> numbersonly(myfield, e, dec) { var key; var keychar; if (window.event) { key = window.event.keyCode; } else if (e) { key = e.which; } …
Read MoreHow to check if the request is an AJAX request with PHP
if (!empty($_SERVER[‘HTTP_X_REQUESTED_WITH’]) && strtolower($_SERVER[‘HTTP_X_REQUESTED_WITH’]) == ‘xmlhttprequest’ ) { // This is ajax request. // write your code here. }
Read More