robert_gsfame
Members-
Posts
876 -
Joined
-
Last visited
Everything posted by robert_gsfame
-
okay so anything that deals with string, !== must be used instead of != which should be used for numeric (integer)
-
what do u mean identical and equal, i really confused this is not about mysql but javascript function and php could u please explain a bit.....equal means everything that cope with number and identical for character??
-
which one is correct if(blablabla !=="") or (blablabla !="") both in php and javascript thx
-
<?php if($text=="aaa"){echo "<a href=# onmouseover=changepic() onmouseout=changepic2()>";}else{};?><?php if($text=="aaa"){echo "<img src=bar/column.gif border=0 id=column/><img src=bar/column1.gif border=0 id=column1 style='display:none'/>";}else{echo "<img src=bar/column1.gif border=0 id=column1/>";}?><?php if($text=="aaa"){echo "</a>";}?> and javascript code <script type="text/javascript"> function changepic(){ document.getElementById('column').style.display="none" document.getElementById('column1').style.display="" } </script> <script type="text/javascript"> function changepic2(){ document.getElementById('column1').style.display="none" document.getElementById('column').style.display="" } </script> why wont the image hover????can anyone help me Thx
-
yeah you're right, but user is the king and i have to serve them by providing all tools that simplify the usage of the site
-
how can i create bookmark button and try it in localhost
-
mysql_real_escape_string() small problem
robert_gsfame replied to robert_gsfame's topic in PHP Coding Help
okay...this problem solve but what if i create a dynamic query for example $a=$_GET['a']; if(!empty($a)){ $a="AND name LIKE'%".$a."%'";} and i wish this query to be execute using mysql_real_escape_string() SELECT * FROM table1 WHERE column1='record1' $a so that when $a not empty i will have this query SELECT * FROM table1 WHERE column1='record1' AND name LIKE '%a%' else SELECT * FROM table1 WHERE column1='record1' -
mysql_real_escape_string() small problem
robert_gsfame replied to robert_gsfame's topic in PHP Coding Help
cause i have "apple,orange,grapes" and i want to match whether i have apple or not in that record therefore i use LIKE % % but i am confused when combining it with mysql_real_escape_string() -
How to create a query using LIKE clause assume mysql_query(sprintf("SELECT * FROM table WHERE name LIKE '% %'", mysql_real_escape_string($username) Where should i put '%s' thx
-
a href=javascript:void(0) not working in IE 6.0, so what should i do so that i can get the same result as when using javascript:void(0)
-
i try to avoid whitespace once being decode
-
okay i think i've found what cause the problem if($find>0){ $_SESSION['basket'][$x]=base64_encode(urlencode($explode[$i]));}} it should be equal to zero not greater
-
I try to create add to carts, but i face this problem..below i attach the code assume checkvalue= 6;8...then i explode the value using ";" as the separator and then i loop the value and check whether there is an old SESSION already...if not then i set the new one or else adding (+1) the new session array. besides i don't want the same record to be stored in $_SESSION array so i check it first 2 problems occured: * When $_SESSION['basket'][0] not yet exist, i fail to create the new one * i still can store the same record again and again although i have the old one $checkvalue=$_GET['checkvalue']; $explode=explode(";",$checkvalue); $count=count($explode); $countbasket=count($_SESSION['basket']); for($i=0;$i<$count;$i++){ if(!isset($_SESSION['basket'][0])){ $x=0;}else{ $total=count($_SESSION['basket']); $x=$total+1;} $find=0; for($a=0;$a<$countbasket;$a++){ if(base64_encode(urlencode($explode[$i]))==$_SESSION['basket'][$a]){ $find++;}} if($find>0){ $_SESSION['basket'][$x]=base64_encode(urlencode($explode[$i]));}} thanks for any helps
-
Yeah dg.* solve everything.....THX A LOT!!!
-
I got some clue now.......i have to state one by one records that i want to SELECT, so instead of using *, i have to state dg.id
-
Just for info, there is no problem in retrieving other records except id
-
this is just some code $selectquery=mysql_query("SELECT * FROM detail dg JOIN userlist dp ON dg.username=dp.username WHERE dg.province='Austin' LIMIT 0, 5"); while($selectarray=mysql_fetch_array($selectquery)){ $selectid=$selectarray['id']; echo $selectid."<br>"; }
-
I have tried to retrieve the record ['id'] which is an autoincrement number from database using mysql_fetch_array but then instead of getting the same result as what stored in database, i get this : 1 database: 25, 3, 7 mysql_fetch_array: 1, 1, 1 what is actually cause the problem, can anyone help me? thx
-
The problem is that if there is more than 1 checked checkbox, then how can i get both values
-
I have dynamic checkboxes, so that number of checkboxes appeared depends on users then how can i get the value from checked checkbox let say i have this $id is the data that i retrieve from database <input type="checkboxes" value=<?php echo $id;?>><a href=javascript:void(0) onclick="getvalue()"> thx
-
stupid me.....i use <span>......anyway i found the hover effect works well in both browsers! THANKS NANO....!!!!!
-
nano..it works well only in FF browser but not IE 6.0
-
still confused.....i am really new to css..so could u please be more specific I add <a href="aaa.php" onmouseover="effect()" id="hyperlink"> javascript: function effect{ document.getElementById("hyperlink").style.bgcolor = "#990000";} nothing was happen
-
I have this <a href="aaa.php" class="pagination">a</a> .pagination{border:1px solid #CCCCCC; display:block;float:left; margin-left:2px;padding-left:4px; padding-right:4px;padding-top:2px;padding-bottom:2px;} how to create the hover effect so that once the cursor touch the text, then the box background will turn from #CCCCCC into #990000 I have the problem with the padding as it prevents me from getting the hover effect perfectly
-
I just want to know how they create a tab and open after mouse over it in let say 2 seconds i usually use this onmouseover this.showPanel(tab);