Jump to content

vijay

Members
  • Posts

    323
  • Joined

  • Last visited

1 Follower

About vijay

  • Birthday 08/18/1984

Contact Methods

  • Website URL
    http://www.w3schools.com
  • ICQ
    0

Profile Information

  • Location
    India
  • Interests
    PHP,Smarty,JAVA SCRIPT<br />MYSQL,MS-SQL,ACCESS

Recent Profile Visitors

11,060 profile views

vijay's Achievements

Member

Member (2/7)

0

Reputation

  1. Hi..SELECT * FROM tbl_name ORDER BY RAND( ) LIMIT 5 from the above qry u will have any random 5 records from the specified table name..I think suppose this thing you want.. isn't it..?Regards,Vijay
  2. Hi..yes you can do for thatyou have to common connection code @ one file "connect.php"and that file you have to require_once @ where ever you want..I mean suppose this you want to say..am i right..?Regards,Vijay
  3. Hi...No that would not be work even if with tthe persistan link also with mysql_pconnect();If you found the other way then tell me...you can do the following (probably that u know..): <?phpsession_start();$link=mysql_connect("localhost","root","");$sel_db=mysql_select_db("db_name");$qry="SELECT * FROM table WHERE language = 'english' ORDER BY id DESC LIMIT 12";$result=mysql_query($qry,$link);echo 'This is all of our members<br /><br />';while($row = mysql_fetch_array($result)){ echo $row['username']; echo '<br />';}?> Regards,Vijay
  4. vijay

    CSS in PHP file

    Hi..u can do that by following..ob_start();include('s.php');ob_clean();tell this file as t.php..but with this you can not apply css in ur pagebut may I know why u r doing silly thing.. am not getting..Regards,Vijay
  5. Hi..see the following code..you will get the things what to do..you have to do same over there.. function func1($param){ return func2($param*10);}function func2($param){ return $param*30;}$param=10;$ret_val=func1($param);echo "return Value: ".$ret_val."</br>"; Regards,Vijay
  6. vijay

    CSS in PHP file

    Hi.. It would be working fine if that file containg css.. but you must enter css name over there as a standards..Regards,Vijay
  7. vijay

    SQL SELECT troubles...

    Hi.. May I have full table structure of those both tables.. I have also try like this: category: cat_a,cat directory: bname,btel SELECT c.cat, concat(d.bname,' ',d.btel) FROM `cat` AS `c` inner join directory as `d` on c.id = d.cat_id order by cat asc Suppose this will help u..Regards,Vijay
  8. vijay

    any ajax based chat?

    Hi.. Is there any chat script or demo based on only AJAX and JAVASCRIPT..? IN php... No use of database.. have got and made but not too good enough and simultaneous.. Thanks in advance..Regards,Vijay
  9. Hi..yes u r right..Regards,Vijay
  10. hi.. which version of mysql r u using..? subqry support available in >= mysql 4.1 version Regards,Vijay
  11. Hi,yes Its possible if both's directory page's session var are samebut you have to check that this things not have any side effects..Regards,Vijay
  12. vijay

    using more sessions

    Hi,try to ammend this line echo "<meta http-equiv=\"Refresh\" content=\"0\" URL=\"profile.php\"/><center>redirect</center>";othewise check the is it redirecting on 'profile.php'if yes then check the content of 'profile.php'or its still remain in 'login.php'try to debug the code line by line and check where ur control goes.. suppose this will help you..Regards,Vijay
  13. vijay

    Is It Possible?

    Hi.. I dont know whether there i any other way except refresh the page.. with the help of AJAX you can do this at regular interval you have to call that file which will give us "last modified time" of that file.. Regards, Vijay
  14. Hi use the following qry:Table: cat - id, cat Table: product - id,cat_id,product_nameSELECT * FROM `cat` WHERE id NOT IN ( SELECT DISTINCT ( cat_id ) FROM product )Regards,Vijay
  15. Hi..Use the following code... and modify according ur req.. <?phprequire_once("functions.php");//_pr(gd_info());//$size = getimagesize("./image/Blue hills.jpg");//_pr($size,1);$uid=uniqid();$random_str=substr($uid,-6);header("Content-type: image/png");$im = @imagecreate(50, 30) or die("Cannot Initialize new GD image stream");$w = imagecolorallocate($im, 255, 255, 255);$red = imagecolorallocate($im, 255, 0, 0);$background_color = imagecolorallocate($im, 255, 255, 255);$text_color = imagecolorallocate($im, 233, 14, 91);$black = imagecolorallocate($im, 0, 0, 0);// prints a black "P" in the top left corner//imagechar($im, 1, 0, 0, $random_str, $text_color);imagestring($im, 5, 5, 5, $random_str, $text_color);imagepng($im);imagedestroy($im);?> Regards,Vijay
×
×
  • Create New...