mysql_fetch_array, row, assoc... yet another newbie question

PHP programming forum. Ask questions or help people concerning PHP code. Don't understand a function? Need help implementing a class? Don't understand a class? Here is where to ask. Remember to do your homework!

Moderator: General Moderators

Post Reply
imstupid
Forum Commoner
Posts: 84
Joined: Fri Feb 18, 2005 1:24 pm

mysql_fetch_array, row, assoc... yet another newbie question

Post by imstupid »

sorry in advance. I've done this successfully in the past many times... that family of possums that live in my head must be multiplying again. Here's the code

Code: Select all

<?php

	$existingeventname = $_REQUEST['existingeventname'] ;

// connect to database code here, blah blah

	$eventname = mysql_query("SELECT eventname FROM eventstable WHERE eventname='$existingeventname'") 
		or die(mysql_error()); 
	$oen = mysql_fetch_array( $eventname )
  		or die(mysql_error()); 

	echo $oen ;	

?>
I get nothing. it prints nothing. I do have an apostrophe in that row though (it reads as Billy's Magical Hamburgers after I strip slashes), but I don't need to add or strip slashes right since the values match? When I echo $existingeventname, it prints fine.


but when I echo $oen, shouldn't I get: Billy\'s Magical Hamburgers printed though, just as I do when I echo $existingeventname since they are the same?

I know this question is really basic. sorry.the past many times... that family of possums that live in my head must be multiplying again. Here's the code

Code: Select all

<?php

	$existingeventname = $_REQUEST['existingeventname'] ;

// connect to database code here, blah blah

	$eventname = mysql_query("SELECT eventname FROM eventstable WHERE eventname='$existingeventname'") 
		or die(mysql_error()); 
	$oen = mysql_fetch_array( $eventname )
  		or die(mysql_error()); 

	echo $oen ;	

?>
I get nothing. it prints nothing. I do have an apostrophe in that row though (it reads as Billy's Magical Hamburgers after I strip slashes), but I don't need to add or strip slashes right since the values match? When I echo $existingeventname, it prints fine.


butssums that live in my head must be multiplying again. Here's the code

Code: Select all

<?php

	$existingeventname = $_REQUEST['existingeventname'] ;

// connect to database code here, blah blah

	$eventname = mysql_query("SELECT eventname FROM eventstable WHERE eventname='$existingeventname'") 
		or die(mysql_error()); 
	$oen = mysql_fetch_array( $eventname )
  		or die(mysql_error()); 

	echo $oen ;	

?>
I get nothing. it prints nothing. I do have an apostrophe in that row though (it reads as Billy's Magical Hamburgers after I strip slashes), but I don't need to add o Here's the code

Code: Select all

<?php

	$existingeventname = $_REQUEST['existingeventname'] ;

// connect to database code here, blah blah

	$eventname = mysql_query("SELECT eventname FROM eventstable WHERE eventname='$existingeventname'") 
		or die(mysql_error()); 
	$oen = mysql_fetch_array( $eventname )
  		or die(mysql_error()); 

	echo $oen ;	

?>
I get nothing. it prints nothing. I do have an apostrophe in that row though (it reads as Billy's Magical Hamburgers after I strip slashes), but I don't need to add or strip slashes right since the values matce multiplying again. Here's the code

Code: Select all

<?php

	$existingeventname = $_REQUEST['existingeventname'] ;

// connect to database code here, blah blah

	$eventname = mysql_query("SELECT eventname FROM eventstable WHERE eventname='$existingeventname'") 
		or die(mysql_error()); 
	$oen = mysql_fetch_array( $eventname )
  		or die(mysql_error()); 

	echo $oen ;	

?>
I get nothing. it prints nothing. I do have an apostrophe in that row though (it reads as Billy's MI've done this successfully in the past many times... that family of possums that live in my head must be multiplying again. Here's the code

Code: Select all

<?php

	$existingeventname = $_REQUEST['existingeventname'] ;

// connect to database code here, blah blah

	$eventname = mysql_query("SELECT eventname FROM eventstable WHERE eventname='$existingeventname'") 
		or die(mysql_error()); 
	$oen = mysql_fetch_array( $eventname )
  		or die(mysql_error()); 

	echo $oen ;	

?>
I get nothing. it prints nothing. I do have an apostrophe in that row though (it reads as Billy's Magical Hamburgers after I strip slashes), but I don't need to add or strip slashes right since the values match? When I echo $existingeventname, it prints fine.


but when I echo $oen, shouldn't I get: Billy\'s Magical Hamburgers printed though, just as I do when I echo $existingeventname since they aI've done this successfully in the past many times... that family of possums that live in my head must be multiplying again. Here's the code

Code: Select all

<?php

	$existingeventname = $_REQUEST['existingeventname'] ;

// connect to database code here, blah blah

	$eventname = mysql_query("SELECT eventname FROM eventstable WHERE eventname='$existingeventname'") 
		or die(mysql_error()); 
	$oen = mysql_fetch_array( $eventname )
  		or die(mysql_error()); 

	echo $oen ;	

?>
I get nothing. it prints nothing. I do have an apostrophe in that row though (it reads as Billy's Magical Hamburgers after I strip slashes), but I don't need to add or strip slashes right since the values match? When I echo $existingeventname, it prints fine.


but when I echo $oen, shouldn't I get: Billy\'s Magical Hamburgers printed though, just as I do when I echo $existingeventname since they are the same?

I know this question is really basic. sorry.o have an apostrophe in that row though (it reads as Billy's Magical Hamburgers after I strip slashes), but I don't need to add or strip slashes right since the values match? When I echo $existingeventname, it prints fine.


but when I echo $oen, shouldn't I get: Billy\'s Magical Hamburgers printed though, just as I do when I echo $existingeventname since they are the same?

I know this question is really basic. sorry.echo $oen, shouldn't I get: Billy\'s Magical Hamburgers printed though, just as I do when I echo $existingeventname since they are the same?

I know this question is really basic. sorry.ossums that live in my head must be multiplying again. Here's the code

Code: Select all

<?php

	$existingeventname = $_REQUEST['existingeventname'] ;

// connect to database code here, blah blah

	$eventname = mysql_query("SELECT eventname FROM eventstable WHERE eventname='$existingeventname'") 
		or die(mysql_error()); 
	$oen = mysql_fetch_array( $eventname )
  		or die(mysql_error()); 

	echo $oen ;	

?>
I get nothing. it prints nothing. I do have an apostrophe in that row though (it reads as Billy's Magical Hamburgers after I strip slashes), but I don't need to add or strip slashes right since the values match? When head must be multiplying again. Here's the code

Code: Select all

<?php

	$existingeventname = $_REQUEST['existingeventname'] ;

// connect to database code here, blah blah

	$eventname = mysql_query("SELECT eventname FROM eventstable WHERE eventname='$existingeventname'") 
		or die(mysql_error()); 
	$oen = mysql_fetch_array( $eventname )
  		or die(mysql_error()); 

	echo $oen ;	

?>
I get nothing. it prints nothin many times... that family of possums that live in my head must be multiplying again. Here's the code

Code: Select all

<?php

	$existingeventname = $_REQUEST['existingeventname'] ;

// connect to database code here, blah blah

	$eventname = mysql_query("SELECT eventname FROM eventstable WHERE eventname='$existingeventname'") 
		or die(mysql_error()); 
	$oen = mysql_fetch_array( $eventname )
  		or die(mysql_error()); 

	echo $oen ;	

?>
I get nothing. it prints nothing. I do have an apostrophe in that row though (it reads as Billy's Magical Hamburgers after I strip slashes), but I don't need to add or strip slashes right since the values match? When I echo $existingeventname, it prints fine.


but when I echo $oen, shouldn't I get: Billy\'s Magical Hamburgers printed though, just as I do when I echo $existingeventname since they are the same?

I know this question is really basic. sorry.geventname = $_REQUEST['existingeventname'] ;

// connect to database code here, blah blah

$eventname = mysql_query("SELECT eventname FROM eventstable WHERE eventname='$existingeventname'")
or die(mysql_error());
$oen = mysql_fetch_array( $eventname )
or die(mysql_error());

echo $oen ;

?&gt;


I get nothing. it prints nothing. I do have an apostrophe in that row though (it reads as Billy's Magical Hamburgers after I strip slashes), but I don't need to add or strip slashes right since the values match? When I echo $existingeventname, it prints fine.


but when I echo $oen, shouldn't I get: Billy\'s Magical Hamburgers printed though, just as I do when I echo $existingevntstable WHERE eventname='$existingeventname'")
or die(mysql_error());
$oen = mysql_fetch_array( $eventname )
or die(mysql_error());

echo $oen ;

?>


I get nothing. it prints nothing. I do have an apostrophe in that row though (it reads as Billy's Magical Hamburgers after I strip slashes), but I don't need to add or strip slashes right since the values match? When I echo $existingeventname, it prints fine.


but when I echo $oen, shouldn't I get: Billy\'s Magical Hamburgers printed though, just as I ds successfully in the past many times... that family of possums that live in my head must be multiplying again. Here's the code

Code: Select all

<?php

	$existingeventname = $_REQUEST['existingeventname'] ;

// connect to database code here, blah blah

	$eventname = mysql_query("SELECT eventname FROM eventstable WHERE eventname='$existingeventname'") 
		or die(mysql_error()); 
	$oen = mysql_fetch_array( $eventname )
  		or die(mysql_error()); 

	echo $oen ;	

?>
I get nothing. it prints nothing. I do have an apostrophe in that row though (it reads as Billy's Magical Hamburgers after I strip slashes), but I don't need to add or strip slashes right since the values match? When I echo $existingeventname, it prints fine.


but when I echo $oen, shouldn't I get: Billy\'s Magical Hamburgers printed though, just as I do when I echo $existingeventname since they are the same?

I know this question is really basic. sorry.nect to database code here, blah blah

$eventname = mysql_query("SELECT eventname FROM eventstable WHERE eventname='$existingeventname'&quote;)
or die(mysql_error());
$oen = mysql_fetch_array( $eventname )
or die(mysql_error());

echo $oen ;

?&gt;


I get nothing. it prints nothing. I do have an apostrophe in that row though (it reads as Billy's Magical Hamburgers after I strip slashes), but I don't need to add or strip slashes right since the values match? When I echo $existingeventname, it prints fine.


but when I echo $oen, shouldn't I get: Billy\'s Magical Hamburgers printed though, just as I do when I echo $existingeventname since they are the same?

I know this question ='$existingeventname'")
or die(mysql_error());
$oen = mysql_fetch_array( $eventname )
or die(mysql_error());

echo $oen ;

?>


I get nothing. it prints nothing. I do have an apostrophe in that row though (it reads as Billy's Magical Hamburgers after I strip slashes), but I don't need to add or strip slashes right since the values match? When I echo $existingeventname, it prints fine.


but when I echo $oen, shouldn't I get: Billy\'s Magical Hamburgers printed though, just as I do when I echo $existingeventname since they are the same?

I know this question is really basic. sorry.atch? When I echo $existingeventname, it prints fine.


but when I echo $oen, shouldn't I get: Billy\'s Magical Hamburgers printed though, just as I do when I echo $existingeventname since they are the same?

I know this question is really basic. sorry. $_REQUEST['existingeventname'] ;

// connect to database code here, blah blah

$eventname = mysql_query("SELECT eventname FROM eventstable WHERE eventname='$existingeventname'")
or die(mysql_error());
$oen = mysql_fetch_array( $eventname )
or die(mysql_error());

echo $oen ;

?&gt;


I get nothing. it prints nothing. I do have an apostrophe in that row though (it reads as Billy's Magical Hamburgers after I strip slashes), but I don't need to add or strip slashes right since the values match? When I echo $existingeventname, it prints fine.


but , blah blah

$eventname = mysql_query("SELECT eventname FROM eventstable WHERE eventname='$existingeventname'")
or die(mysql_error());
$oen = mysql_fetch_array( $eventname )
or die(mysql_error());

echo $oen ;

?>


I get nothing. it prints nothing. I do have an apostrophe in that row though (it reads as Billy's Magical Hamburgers after I strip slashes), but I don't need to add or strip slashes right since the values match? When I echo $existingeventname, it prints fine.


but when I echo $oen, shouldn't I get: Billy\'s Magical Hamburgers printed though, just as I do when It nothing. it prints nothing. I do have an apostrophe in that row though (it reads as Billy's Magical Hamburgers after I strip slashes), but I don't need to add or strip slashes right since the values match? When I echo $existingeventname, it prints fine.


but when I echo $oen, shouldn't I get: Billy\'s Magical Hamburgers printed though, just as I do when I echo $existingeventname since they are the same?

I know this question is really basic. sorry.I've done this successfully in the past many times... that family of possums that live in my head must be multiplying again. Here's the code

Code: Select all

<?php

	$existingeventname = $_REQUEST['existingeventname'] ;

// connect to database code here, blah blah

	$eventname = mysql_query("SELECT eventname FROM eventstable WHERE eventname='$existingeventname'") 
		or die(mysql_error()); 
	$oen = mysql_fetch_array( $eventname )
  		or die(mysql_error()); 

	echo $oen ;	

?>
I get nothing. it prints nothing. I do have an apostrophe in that row though (it reads as Billy's Magical Hamburgers after I strip slashes), but I don't need to add or strip slashes right since the values match? When I echo $existingeventname, isql_error());
$oen = mysql_fetch_array( $eventname )
or die(mysql_error());

echo $oen ;

?>


I get nothing. it prints nothing. I do have an apostrophe in that row though (it reads as Billy's Magical Hamburgers after I strip slashes), but I don't need to add or strip slashes right since the values match? When I echo $existingeventname, it prints fine.


but when I echo $oen, shouldn't I get: Billy\'s Magical Hamburgers printed though, just as I do when I echo $existingeventname since they are the same?

I know this question is really basic. sorry.n the past many times... that family of possums that live in my head must be multiplying again. Here's the code

Code: Select all

<?php

	$existingeventname = $_REQUEST['existingeventname'] ;

// connect to database code here, blah blah

	$eventname = mysql_query("SELECT eventname FROM eventstable WHERE eventname='$existingeventname'") 
		or die(mysql_error()); 
	$oen = mysql_fetch_array( $eventname )
  		or die(mysql_error()); 

	echo $oen ;	

?>
I get nothing. it prints nothing. I do have an apostrophe in that row though (it reads as Billy's Magical Hamburgers after I strip slashes), but I don't need to add or strip slashes right since the values match? When I echo $existingeventname, it prints fine.


but when I echo $oen, shouldn't I get: Billy\'s Magical Hamburgers printed though, just as I do when I echo $existingeventname since they a;?php

$existingeventname = $_REQUEST['existingeventname'] ;

// connect to database code here, blah blah

$eventname = mysql_query("SELECT eventname FROM eventstable WHERE eventname='$existingeventname'")
or die(mysql_error());
$oen = mysql_fetch_array( $eventname )
or die(mysql_error());

echo $oen ;

?>


I get nothing. it prints nothing. I do have an apostrophe in that row though (it reads as Billy's Magical Hamburgers after I strip slashes), but I don't need to add or strip slashes right since the values match? When I echo $existingeventname, it prints fine.


but when I echo $oen, shouldn't I get: Billy\'s Magical Hamburgers printed though, just as I do when I echo $existingeventname since they are the same?

I know this question is really basic. sorry. in the past many times... that family of possums that live in my head must be multiplying again. Here's the code

Code: Select all

<?php

	$existingeventname = $_REQUEST['existingeventname'] ;

// connect to database code here, blah blah

	$eventname = mysql_query("SELECT eventname FROM eventstable WHERE eventname='$existingeventname'") 
		or die(mysql_error()); 
	$oen = mysql_fetch_array( $eventname )
  		or die(mysql_error()); 

	echo $oen ;	

?>
I get nothing. it prints nothing. I do have an apostrophe in that row though (it reads as Billy's Magical Hamburgers after I strip slashes), but I don't need to add or strip slashes right since the values match? Wheingeventname'] ;

// connect to database code here, blah blah

$eventname = mysql_query("SELECT eventname FROM eventstable WHERE eventname='$existingeventname'")
or die(mysql_error());
$oen = mysql_fetch_array( $eventname )
or die(mysql_error());

echo $oen ;

?>


I get nothing. it prints nothing. I do have an apostrophe in that row though (it reads as Billy's Magical Hamburgers after I strip slashes), but I don't need to add or strip slashes right since the values matcame = $_REQUEST['existingeventname'] ;

// connect to database code here, blah blah

$eventname = mysql_query("SELECT eventname FROM eventstable WHERE eventname='$existingeventname'")
or die(mysql_error());
$oen = mysql_fetch_array( $eventname )
or die(mysql_error());

echo $oen ;

?&gt;


I get nothing. it prints nothing. I do have an apostrophe in that row though (it reads as Billy's Magical Hamburgers after I strip slashes), but I don't need to add or strip slashes right since the values match? When I echo $existingeventname, it prints fine.


but when I echo $oen, shouldn't I get: Billy\'s Magical Hamburgers printed though, just as I do when I echo $e;
$oen = mysql_fetch_array( $eventname )
or die(mysql_error());

echo $oen ;

?>


I get nothing. it prints nothing. I do have an apostrophe in that row though (it reads as Billy's Magical Hamburgers after I strip slashes), but I don't need to add or strip slashes right since the values match? When I echo $existingeventname, it prints fine.


but wFROM eventstable WHERE eventname='$existingeventname'")
or die(mysql_error());
$oen = mysql_fetch_array( $eventname )
or die(mysql_error());

echo $oen ;

?>


I get nothing. it prints nothing. I do have an apostrophe in that row though (it reads as Billy's Magical Hamburgers after I strip slashes), but I don't need to add or strip slashes right since the values match? When I echo $existingeventname, it prints fine.


but when I echo $oen, shouldn't I getn my head must be multiplying again. Here's the code

Code: Select all

<?php

	$existingeventname = $_REQUEST['existingeventname'] ;

// connect to database code here, blah blah

	$eventname = mysql_query("SELECT eventname FROM eventstable WHERE eventname='$existingeventname'") 
		or die(mysql_error()); 
	$oen = mysql_fetch_array( $eventname )
  		or die(mysql_error()); 

	echo $oen ;	

?>
I get nothing. it prints nothing. I do have an apostrophe in that row though (it reads as Billy's Magical Hamburgers after I strip slashes), but I don't need to add or strip slashes right since the values match? When I echo $existingeventname, it prints fine.


but when I echo $oen, shouldn't I get: Billy\'s Magical Hamburgers printed though, just as I do when I echo $existingeventname since they are the same?

I know this question is really basic. sorry.successfully in the past many times... that family of possums that live in my head must be multiplying again. Here's the code

Code: Select all

<?php

	$existingeventname = $_REQUEST['existingeventname'] ;

// connect to database code here, blah blah

	$eventname = mysql_query("SELECT eventname FROM eventstable WHERE eventname='$existingeventname'") 
		or die(mysql_error()); 
	$oen = mysql_fetch_array( $eventname )
  		or die(mysql_error()); 

	echo $oen ;	

?>
I get nothing. it prints nothing. I do have an apostrophe in that row though (it reads as Billy's Magical Hamburgers after I strip slashes), but I don't need to add or strip slashes right since the values match? When I echo $existingeventname, it prints fine.


but when I echo $oen, shouldn't I get: Billy\'s Magical Hamburgers printed though, just as I do when I echo $existingeventname since they are the same?

I know this question is really basic. sorry.istingeventname'")
or die(mysql_error());
$oen = mysql_fetch_array( $eventname )
or die(mysql_error());

echo $oen ;

?>


I get nothing. it prints nothing. I do have an apostrophe in that row though (it reads as Billy's Magical Hamburgers after I strip slashes), but I don't need to add or strip slashes right since the values matI've done this successfully in the past many times... that family of possums that live in my head must be multiplying again. Here's the code

Code: Select all

<?php

	$existingeventname = $_REQUEST['existingeventname'] ;

// connect to database code here, blah blah

	$eventname = mysql_query("SELECT eventname FROM eventstable WHERE eventname='$existingeventname'") 
		or die(mysql_error()); 
	$oen = mysql_fetch_array( $eventname )
  		or die(mysql_error()); 

	echo $oen ;	

?>
I get nothing. it prints nothing. I do have an apostrophe in that row though (it reads as Billy's Magical Hamburgers after I strip slashes), but I don't need to add or strip slashes right since the values match? When I echo $existingeventname, it prints fine.


but when I echo $oen, shouldn't I get: Billy\'s Magical Hamburgers printed though, just as I do when I echo $existingeventntname = $_REQUEST['existingeventname'] ;

// connect to database code here, blah blah

$eventname = mysql_query("SELECT eventname FROM eventstable WHERE eventname='$existingeventname'")
or die(mysql_error());
$oen = mysql_fetch_array( $eventname )
or die(mysql_error());

echo $oen ;

?&gt;


I get nothing. it prints nothing. I do have an apostrophe in that r... that family of possums that live in my head must be multiplying again. Here's the code

Code: Select all

<?php

	$existingeventname = $_REQUEST['existingeventname'] ;

// connect to database code here, blah blah

	$eventname = mysql_query("SELECT eventname FROM eventstable WHERE eventname='$existingeventname'") 
		or die(mysql_error()); 
	$oen = mysql_fetch_array( $eventname )
  		or die(mysql_error()); 

	echo $oen ;	

?>
I get nothing. it prints nothing. I do have an apostrophe in that row though (it reads as Billy's Magical Hamburgers after I strip slashes), but I don't need to add or strip slashes right since the values match? When I echo $existingeventname, it prints fine.


but when I echo $oen, shouldn't I get: Billy\'s Magical Hamburgers printed though, just as I do when I echo $existingeventname since they are the same?

I know this question is really basic. sorryp;amp;lt;?php

$existingeventname = $_REQUESTї'existingeventname'] ;

// connect to database code here, blah blah

$eventname = mysql_query(&quote;SELECT eventname FROM eventstable WHERE eventname='$existingeventname'&quote;)
or die(mysql_error());
$oen = mysql_fetch_array( $eventname )
or die(mysql_error());

echo $oen ;

?>


I get nothing. it prints nothing. I do have an apostrophe in that row though (it reads as Billy's Magical Hamburgers after I strip slashes), but I don't need to add or strip slashes right since the values match? When I echo $existingeventname, it prints fine.


but when I echo $oen, shouldn't I get: Billy\'s Magical Hamburgers printed though, just as I do when I echo $existingeventname since they are the same?

I know this question is really basic. sorry.I've done this successfully in the past many times... that family of possums that live in my head must be multiplying again. Here's the code

Code: Select all

<?php

	$existingeventname = $_REQUEST['existingeventname'] ;

// connect to database code here, blah blah

	$eventname = mysql_query("SELECT eventname FROM eventstable WHERE eventname='$existingeventname'") 
		or die(mysql_error()); 
	$oen = mysql_fetch_array( $eventname )
  		or die(mysql_error()); 

	echo $oen ;	

?>
I get nothing. it prints nothing. I do have an apostrophe in that row though (it reads as Billy's Magical Hamburgers after I strip slashes), but I don't need to add or strip slashes right since the values match? When I echo $existingeventname, it prints fine.


but when I echo $oen, shouldn't I get: Billy\'hp

$existingeventname = $_REQUEST['existingeventname'] ;

// connect to database code here, blah blah

$eventname = mysql_query("SELECT eventname FROM eventstable WHERE eventname='$existingeventname'&quote;)
or die(mysql_error());
$oen = mysql_fetch_array( $eventname )
or die(mysql_error());

echo $oen ;

?>


I get nothing. it prints nothing. I do have an apostrophe in that row though (it reads as Billy's Magical Hamburgers after I strip slashes), but I don't need to add or strip slashes right since the values match? When I echo $existingeventname, it prints fine.


but when I echo $oen,php]
<?php

$existingeventname = $_REQUEST['existingeventname'] ;

// connect to database code here, blah blah

$eventname = mysql_query("SELECT eventname FROM eventstable WHERE eventname='$existingeventname'&quote;)
or die(mysql_error());
$oen = mysql_fetch_array( $eventname )
or die(mysql_error());

echo $oen ;

?>


I get nothing. it prints nothing. I do have an apostrophe in that row though (it reads as Billy's Magical Hamburgers after I strip slashes), but I don't need to add or strip slashes right since the values match? When I echo $existingeventname, it prints nothing. I do have an apostrophe in that row though (it reads as Billy's Magical Hamburgers after I strip slashes), but I don't need to add or strip slashes right since the values match? When I echo $existingeventname, it prints fine.


but when I echo $oen, shouldn't I get: Billy\'s Magical Hamburgers printed though, just as I do when I echo $existingeventname since they are the same?

I know this question is really basic. sorry.entname'")
or die(mysql_error());
$oen = mysql_fetch_array( $eventname )
or die(mysql_error());

echo $oen ;

?>


I get nothing. it prints nothing. I do have an apostrophe in that row though (it reads as Billy's Magical Hamburgers after I strip slashes), but I don't need to add or strip slashes right since the values match? When I echo $existingeventname, it prints fine.


but when I echo $oen, shouldn't I get: Billy\'s Magical Hamburgers printed though, just as I do when I echo $existingeventname since they are the same?

I know this question is really basic. sorry.<?php

$existingeventname = $_REQUEST['existingeventname'] ;

// connect to database code here, blah blah

$eventname = mysql_query("SELECT eventname FROM eventstable WHERE eventname='$existingeventname'")
or die(mysql_error());
$oen = mysql_fetch_array( $eventname )
or die(mysql_error());

echo $oen ;

?>


I get nothing. it prints nothing. I do have an apostrophe in that row though (it reads as Billy's Magical Hamburgers after I strip slashes), but I don't need to add or strip slashes right since the values match? When I echo $existingeventname, it prints fine.


but when I echo $oen, shouldn't I get: Billy\'s Magical Hamburgers printed though, just as I do when I echo $existingeventname since they are the same?

I know this question is really basic. sorry.I've done this successfully in the past many times... that family of possums that live in my head must be multiplying again. Here's the code

Code: Select all

<?php

	$existingeventname = $_REQUEST['existingeventname'] ;

// connect to database code here, blah blah

	$eventname = mysql_query("SELECT eventname FROM eventstable WHERE eventname='$existingeventname'") 
		or die(mysql_error()); 
	$oen = mysql_fetch_array( $eventname )
  		or die(mysql_error()); 

	echo $oen ;	

?>
I get nothing. it prints nothing. I do have an apostrophe in that row though (it reads as Billy's Magical Hamburgers after I strip slashes), but I don't need to add or strip slashes right since the values match? When I echo $existingeventname, it prints fine.


but when I echo $oen, shouldn't I get: Billy\'s Magical Hamburgers printed though, just as I do when I echo $existingeventname since they are the same?

I know this quely of possums that live in my head must be multiplying again. Here's the code

Code: Select all

<?php

	$existingeventname = $_REQUEST['existingeventname'] ;

// connect to database code here, blah blah

	$eventname = mysql_query("SELECT eventname FROM eventstable WHERE eventname='$existingeventname'") 
		or die(mysql_error()); 
	$oen = mysql_fetch_array( $eventname )
  		or die(mysql_error()); 

	echo $oen ;	

?>
I get nothing. it prints nothing. Illy in the past many times... that family of possums that live in my head must be multiplying again. Here's the code

Code: Select all

<?php

	$existingeventname = $_REQUEST['existingeventname'] ;

// connect to database code here, blah blah

	$eventname = mysql_query("SELECT eventname FROM eventstable WHERE eventname='$existingeventname'") 
		or die(mysql_error()); 
	$oen = mysql_fetch_array( $eventname )
  		or die(mysql_error()); 

	echo $oen ;	

?>
I get nothing. it prints nothing. I do have an apostrophe in that row though (it reads as Billy's Magical Hamburgers after I strip slashes), but I don't need to add or strip slashes right since the values match? When I echo $existingeventname, it prints fine.


but when I echo $oen, shouldn't I get: Billy\'s Magical Hamburgers printed though, just as I do when I echo $existingeventname since they are the same?

I know this question is really basic. sorry.rror());
$oen = mysql_fetch_array( $eventname )
or die(mysql_error());

echo $oen ;

?>


I get nothing. it prints nothing. I do have an apos4be966a]
<?php

$existingeventname = $_REQUEST['existingeventname'] ;

// connect to database code here, blah blah

$eventname = mysql_query(&quote;SELECT eventname FROM eventstable WHERE eventname='$existingeventname'&quote;)
or die(mysql_error());
$oen = mysql_fetch_array( $eventname )
or die(mysql_error());

echo $oen ;

?&gt;


I get nothing. it prints nothing. I do have an apostrophe in that row though (it reads as Billy's Magical Hamburgers after I strip slashes), but I don't need to add or strip slashes right since the values match? When I echo $existingeventname, it prints fine.


but when I echo $oultiplying again. Here's the code

Code: Select all

<?php

	$existingeventname = $_REQUEST['existingeventname'] ;

// connect to database code here, blah blah

	$eventname = mysql_query("SELECT eventname FROM eventstable WHERE eventname='$existingeventname'") 
		or die(mysql_error()); 
	$oen = mysql_fetch_array( $eventname )
  		or die(mysql_error()); 

	echo $oen ;	

?>
I get nothing. it prints nothing. I do have an apostrophe in that row though (it reads as Billy's Magical Hamburgers after I strip slashes), but I don't need to add or strip slashes right since the values match? When I echo $existingeventname, it prints fine.


but when I echo $oen, shouldn't I get: Billy\'s Magical Hamburgers printed though, just as I do when I echo $existingeventname since they are the same?

I know this question is really basic. sorry.n the past many times... that family of possums that live in my head must be multiplying again. Here's the code

Code: Select all

<?php

	$existingeventname = $_REQUEST['existingeventname'] ;

// connect to database code here, blah blah

	$eventname = mysql_query("SELECT eventname FROM eventstable WHERE eventname='$existingeventname'") 
		or die(mysql_error()); 
	$oen = mysql_fetch_array( $eventname )
  		or die(mysql_error()); 

	echo $oen ;	

?>
I get nothing. it prints nothing. I do have an apostrophe in that row though (it reads as Billy's Magical Hamburgers after I strip slashes), but I don't need to add or strip slashes righ]
<?php

$existingeventname = $_REQUESTї'existingeventname'] ;

// connect to database code here, blah blah

$eventname = mysql_query(&quote;SELECT eventname FROM eventstable WHERE eventname='$existingeventname'&quote;)
or die(mysql_error());
$oen = mysql_fetch_array( $eventname )
or die(mysql_error());

echo $oen ;

?&gt;


I get nothing. it prints nothing. I do have an apostrophe in that row though (it reads as Billy's Magical Hamburgers after I strip slashes), but I don't need to add or strip slashes right since the values match? When I echo $existingeventname, it prints fine.


at live in my head must be multiplying again. Here's the code

Code: Select all

<?php

	$existingeventname = $_REQUEST['existingeventname'] ;

// connect to database code here, blah blah

	$eventname = mysql_query("SELECT eventname FROM eventstable WHERE eventname='$existingeventname'") 
		or die(mysql_error()); 
	$oen = mysql_fetch_array( $eventname )
  		or die(mysql_error()); 

	echo $oen ;	

?>
I get nothing. it prints nothing. I do have an apostrophe in that row though (it reads as Billy's Magical Hamburgers after I strip slashes), but I don't need to add or strip slashes right since the values match? When I echo $existingeventname, it prints fine.


but when I echo $oen, shouldn't I get: Billy\'s Magical Hamburgers printed though, just as I do when I echo $existingeventname since they are the same?

I know this question is really basic. sorry.r die(mysql_error());
$oen = mysql_fetch_array( $eventname )
or die(mysql_error());

echo $oen ;

?>


I get nothing. it prints nothing. I do have an apostrophe in that row though (it reads as Billy's Magical Hamburgers after I strip slashes), but I don't need to add or strip slashes right since the values match? When I echo $existingeventname, it prints fine.


but when I echo $oen, shouldn't I get: Billy\'s Magical Hamburgers printed though, just as I do when I echo $existingeventname since they are the same?

I know this question is really basic. sorry.WHERE eventname='$existingeventname'")
or die(mysql_error());
$oen = mysql_fetch_array( $eventname )
or die(mysql_error());

echo $oen ;

?&gt;


I get nothing. it prints nothing. I do have an apostrophe in that row though (it rn. Here's the code

Code: Select all

<?php

	$existingeventname = $_REQUEST['existingeventname'] ;

// connect to database code here, blah blah

	$eventname = mysql_query("SELECT eventname FROM eventstable WHERE eventname='$existingeventname'") 
		or die(mysql_error()); 
	$oen = mysql_fetch_array( $eventname )
  		or die(mysql_error()); 

	echo $oen ;	

?>
I get nothing. it prints nothing. I do have an apostrophe in that row though (it reads as Billy's Magical Hamburgers after I strip slashes), but I don't need to add or strip slashes right since the values match? When I echo $existingeventname, it prints fine.


but when I echmp;amp;lt;?php

$existingeventname = $_REQUEST['existingeventname'] ;

// connect to database code here, blah blah

$eventname = mysql_query(&quote;SELECT eventname FROM eventstable WHERE eventname='$existingeventname'&quote;)
or die(mysql_error());
$oen = mysql_fetch_array( $eventname )
or die(mysql_error());

echo $oen ;

?&gt;


I get nothing. it prints nothing. I do have an apostrophe in that row though (it reads as Billy's Magical Hamburgers after I strip slashes), but I don't need to add or strip slashes right since the values match? When I echo $existingeventname, it prints fine.


but when I echo $oen, shouldn't I get: Billy\'s Magical Hamburgers printed though, just as I do when I echo $existingeventname since they are the same?

I know this question is really basic. sorry.in my head must be multiplying again. Here's the code

Code: Select all

<?php

	$existingeventname = $_REQUEST['existingeventname'] ;

// connect to database code here, blah blah

	$eventname = mysql_query("SELECT eventname FROM eventstable WHERE eventname='$existingeventname'") 
		or die(mysql_error()); 
	$oen = mysql_fetch_array( $eventname )
  		or die(mysql_error()); 

	echo $oen ;	

?>
I get nothing. it prints nothing. I do have an apostrophe in that row though (it reads as Billy's Magical Hamburgers after I strip slashes), but I don't need to add or strip slashes right since the values match? When I echo $existingeventname, it prints fine.


but when I echo $oen, shouldn't I get: Billy\'s Magical Hamburgers printed though,e multiplying again. Here's the code

Code: Select all

<?php

	$existingeventname = $_REQUEST['existingeventname'] ;

// connect to database code here, blah blah

	$eventname = mysql_query("SELECT eventname FROM eventstable WHERE eventname='$existingeventname'") 
		or die(mysql_error()); 
	$oen = mysql_fetch_array( $eventname )
  		or die(mysql_error()); 

	echo $oen ;	

?>
I get nothing. it prints nothing. I do have an apostrophamily of possums that live in my head must be multiplying again. Here's the code

Code: Select all

<?php

	$existingeventname = $_REQUEST['existingeventname'] ;

// connect to database code here, blah blah

	$eventname = mysql_query("SELECT eventname FROM eventstable WHERE eventname='$existingeventname'") 
		or die(mysql_error()); 
	$oen = mysql_fetch_array( $eventname )
  		or die(mysql_error()); 

	echo $oen ;	

?>
I get nothing. it prints nothing. I do have ny times... that family of possums that live in my head must be multiplying again. Here's the code

Code: Select all

<?php

	$existingeventname = $_REQUEST['existingeventname'] ;

// connect to database code here, blah blah

	$eventname = mysql_query("SELECT eventname FROM eventstable WHERE eventname='$existingeventname'") 
		or die(mysql_error()); 
	$oen = mysql_fetch_array( $eventname )
  		or die(mysql_error()); 

	echo $oen ;	

?>
I get nothing. it prints nothing. I do have an apostrophe in that row though (it reads as Billy's Magical Hamburgers after I strip slashes), but I don't need to add or strip slashes right since the values match? When I echo $existin in my head must be multiplying again. Here's the code

Code: Select all

<?php

	$existingeventname = $_REQUEST['existingeventname'] ;

// connect to database code here, blah blah

	$eventname = mysql_query("SELECT eventname FROM eventstable WHERE eventname='$existingeventname'") 
		or die(mysql_error()); 
	$oen = mysql_fetch_array( $eventname )
  		or die(mysql_error()); 

	echo $oen ;	

?>
I get nothing. it prints nothing. I do have an apostrophe in that row though (it reads as Billy's Magical Hamburgers after I strip slashes), but I don't nlt;?php

$existingeventname = $_REQUEST['existingeventname'] ;

// connect to database code here, blah blah

$eventname = mysql_query("SELECT eventname FROM eventstable WHERE eventname='$existingeventname'")
or die(mysql_error());
$oen = mysql_fetch_array( $eventname )
or die(mysql_error());

echo $oen ;

?&gt;


I get nothing. it prints nothing. I do have an apostrophe in that row though (it reads as Billy's Magical Hamburgers after I strip slashes), but I don't need to add or strip slashes right since the values match? When I echo $existingeventname, it prints fine.


but when I echo $oen, shouldn't I get: Billy\'s Magical Hamburgers printed ingeventname'")
or die(mysql_error());
$oen = mysql_fetch_array( $eventname )
or die(mysql_error());

echo $oen ;

?>


I get nothing. it prints nothing. I do have an apostrophe in that row though (it reads as Billy's Magical Hamburgers after I strip slashes), but I don't need to add or strip slashes right since the values match? When I echo $existingeventname, it prints fine.


but when I echo $oen, shouldn't I get: Billy\'s Magical Hamburgers printed though, just as I do when I echo $existingeventname since they are the same?

I know this question is really basic. sorry.amily of possums that live in my head must be multiplying again. Here's the code

Code: Select all

<?php

	$existingeventname = $_REQUEST['existingeventname'] ;

// connect to database code here, blah blah

	$eventname = mysql_query("SELECT eventname FROM eventstable WHERE eventname='$existingeventname'") 
		or die(mysql_error()); 
	$oen = mysql_fetch_array( $eventname )
  		or die(mysql_error()); 

	echo $oen ;	

?>
I get nothing. it prints nothing. I do have an apostrophe in that row though (it reads as Billy's Magical Hamburgers after I strip slashes), but I don't need to add or strip slashes right since the vs... that family of possums that live in my head must be multiplying again. Here's the code

Code: Select all

<?php

	$existingeventname = $_REQUEST['existingeventname'] ;

// connect to database code here, blah blah

	$eventname = mysql_query("SELECT eventname FROM eventstable WHERE eventname='$existingeventname'") 
		or die(mysql_error()); 
	$oen = mysql_fetch_array( $eventname )
  		or die(mysql_error()); 

	echo $oen ;	

?>
I get nothing. it prints nothing. I do have an apostrophe in that row though (it reads as Billy's Magical Hamburgers after I strip slashes), but I don't need to add or strip slashes right since the values match? When I echo $existingeventname, it prints fine.


but when I echo $oen, shouldn't I get: Billy\'s Magical Hamburgers printed though, just as I do when I echo $existingeventname since they are the same?

I know this question is really basic. sorry.= mysql_query("SELECT eventname FROM eventstable WHERE eventname='$existingeventname'")
or die(mysql_error());
$oen = mysql_fetch_array( $eventname )
or die(mysql_error());

echo $oen ;

?>


I get nothing. it prints nothing. I do have an apostrophe in that row though (it reads as Billy's Magical Hamburgers after I strip slashes), but I don't need to add or strip slashes rigccessfully in the past many times... that family of possums that live in my head must be multiplying again. Here's the code

Code: Select all

<?php

	$existingeventname = $_REQUEST['existingeventname'] ;

// connect to database code here, blah blah

	$eventname = mysql_query("SELECT eventname FROM eventstable WHERE eventname='$existingeventname'") 
		or die(mysql_error()); 
	$oen = mysql_fetch_array( $eventname )
  		or die(mysql_error()); 

	echo $oen ;	

?>
I get nothing. it prints nothing. I do have an apostrophe in that row though (it reads as Billy's Magical Hamburgers after I strip slashes), but I don't need to add or strip slashes right since the values match? When I echo $existingeventname, it prints fine.


but when I echo $oen, shouldn't I get: Billy\'s Magical Hamburgers printed though, just as I do when I echo $existingeventname since they are the same?

I know this question is really basic. sorry.
// connect to database code here, blah blah

$eventname = mysql_query("SELECT eventname FROM eventstable WHERE eventname='$existingeventname'&quote;)
or die(mysql_error());
$oen = mysql_fetch_array( $eventname )
or die(mysql_error());

echo $oen ;

?&gt;


I get nothing. it prints nothing. I do have an apostrophe in that row though (it reads as Billy's Magical Hamburgers after I strip slashes), but I donast many times... that family of possums that live in my head must be multiplying again. Here's the code

Code: Select all

<?php

	$existingeventname = $_REQUEST['existingeventname'] ;

// connect to database code here, blah blah

	$eventname = mysql_query("SELECT eventname FROM eventstable WHERE eventname='$existingeventname'") 
		or die(mysql_error()); 
	$oen = mysql_fetch_array( $eventname )
  		or die(mysql_error()); 

	echo $oen ;	

?>
I get nothing. it prints nothing. I do have an apostrophe in that row though family of possums that live in my head must be multiplying again. Here's the code

Code: Select all

<?php

	$existingeventname = $_REQUEST['existingeventname'] ;

// connect to database code here, blah blah

	$eventname = mysql_query("SELECT eventname FROM eventstable WHERE eventname='$existingeventname'") 
		or die(mysql_error()); 
	$oen = mysql_fetch_array( $eventname )
  		or die(mysql_error()); 

	echo $oen ;	

?>
I get nothing. it prints nothing. I do have an apostrophe in that row though (it reads as Billy's Magical Hamburgers after I strip slashes), but I don't need to add or ststingeventname'] ;

// connect to database code here, blah blah

$eventname = mysql_query("SELECT eventname FROM eventstable WHERE eventname='$existingeventname'")
or die(mysql_error());
$oen = mysql_fetch_array( $eventname )
or die(mysql_error());

echo $oen ;

?&gt;


I get nothing. it prints nothing. I do have an apostrophe in that row though (it reads as Billy's Magical Hamburgers after I strip slashes), but I don't need to add or strip slashes right since the values match? When I echo $existingeventname, it prints fine.


but when I echo $oen, shouldn't I get: Billy\'s Magical Hamburgers printed though, just as I do when I echo $existingeventname since they are the same?

I know this qical Hamburgers after I strip slashes), but I don't need to add or strip slashes right since the values match? When I echo $existingeventname, it prints fine.


but when I echo $oen, shouldn't I get: Billy\'s Magical Hamburgers printed though, just as I do when I echo $existingeventname since they are the same?

I know this question is really basic. sorry.many times... that family of possums that live in my head must be multiplying again. Here's the code

Code: Select all

<?php

	$existingeventname = $_REQUEST['existingeventname'] ;

// connect to database code here, blah blah

	$eventname = mysql_query("SELECT eventname FROM eventstable WHERE eventname='$existingeventname'") 
		or die(mysql_error()); 
	$oen = mysql_fetch_array( $eventname )
  		or die(mysql_error()); 

	echo $oen ;	

?>
I get nothing. it prints nothing. I do have an apostrophe in that row though (it reads as Billy's Magical Hamburgers after I strip slashes), but I don't need to add or strip slashes right since the values match? When I echo $existingeventname, it prints finof possums that live in my head must be multiplying again. Here's the code

Code: Select all

<?php

	$existingeventname = $_REQUEST['existingeventname'] ;

// connect to database code here, blah blah

	$eventname = mysql_query("SELECT eventname FROM eventstable WHERE eventname='$existingeventname'") 
		or die(mysql_error()); 
	$oen = mysql_fetch_array( $eventname )
  		or die(mysql_error()); 

	echo $oen ;	

?>
I get nothing. it prints nothing. I do have an apostrophe in that row though (it reads as Billy's Magical Hamburgers a
<?php

$existingeventname = $_REQUEST['existingeventname'] ;

// connect to database code here, blah blah

$eventname = mysql_query("SELECT eventname FROM eventstable WHERE eventname='$existingeventname'")
or die(mysql_error());
$oen = mysql_fetch_array( $eventname )
or die(mysql_error());

echo $oen ;

?>


I get nothing. it prints nothing. I do have an apostrophe in that row though (it reads as Billy's Magical Hamburgers after I strip slashes), but I don't need to add or strip slashes right since the values match? When I echo $existingeventname, it prints fine.


but when I echo $oen, shouldn't I get: Billy\'s Magical Hamburgers printed though, just as I do when I echo $existingeventname since they are the same?

I know this question is really basic. sorry.
imstupid
Forum Commoner
Posts: 84
Joined: Fri Feb 18, 2005 1:24 pm

Post by imstupid »

edit:
I forgot about doing this regarding the posting above:

Code: Select all

echo $oen['eventname'] ;
when the row does not have and apostrophe's, it prints like a charm, but if it does, nothing.osting above:

Code: Select all

echo $oen['eventname'] ;
when the row does not have and apostrophe's, it prints like a charm, but if it does, nothing.o $oen['eventname'] ;


when the row does not have and apostrophe's, it prints like a charm, but if it does, nothing.
when the row does not have and apostrophe's, it prints like a charm, but if it does, nothing.php]

when the row does not have and apostrophe's, it prints like a charm, but if it does, nothing.bout doing this regarding the posting above:

Code: Select all

echo $oen['eventname'] ;
when the row does not have and apbout doing this regarding the posting above:

Code: Select all

echo $oen['eventname'] ;
when the row does not have and apostrophe's, it prints like a charm, but if it does, nothing.ho $oen['eventname'] ;


when the row does not have and apostrophe's, it prints like a charm, but if it does, nothing.e'] ;


when the row does not have and apostrophe's, it prints like a charm, but if it does, nothing.bove:

Code: Select all

echo $oen['eventname'] ;
when the row does not have and apostrophe's, it prints like a charm, but if it does, nothing.m, but if it does, nothing.is regarding the posting above:

Code: Select all

echo $oen['eventname'] ;
when the row does not have and apostrophe's, it prints like a charm, but if it does, nothing. does, nothing.bout doing this regarding the posting above:

Code: Select all

echo $oen['eventname'] ;
when the row does not have and apostrophe's, it prints like a charm, but if it does, nothing. posting above:

Code: Select all

echo $oen['eventname'] ;
when the row does not have and apostrophe's, it prints like a charm, but if it does, nothing.prints like a charm, but if it does, nothing.he posting above:

Code: Select all

echo $oen['eventname'] ;
when the row does not have and apostrophe's, it prints like a charm, but if it does, nothing.if it does, nothing.ntname'] ;


when the row does not have and apostrophe's, it prints like a charm, but if it does, nothing. regarding the posting above:

Code: Select all

echo $oen['eventname'] ;
when the row does not have and apostrophe's, it prints like a charm, but if it does, nothing.bout doing this regarding the posting above:

Code: Select all

echo $oen['eventname'] ;
when the row does not have and apostrophe's, it prints like a charm, but if it does, nothing.ut if it does, nothing.hp]
echo $oen['eventname'] ;


when the row does not have and apostrophe's, it prints like a charm, but if it does, nothinge's, it prints like a charm, but if it does, nothing.bout doing this regarding the posting above:

Code: Select all

echo $oen['eventname'] ;
when the row does not have and apostrophe's, it prints like a charm, but if it does, nothing.nts like a charm, but if it does, nothing.not have and apostrophe's, it prints like a charm, but if it does, nothing.ophe's, it prints like a charm, but if it does, nothing.bout doing this regarding the posting above:

Code: Select all

echo $oen['eventname'] ;
when the row does not have and apostrophe's, it prints like a che7]
echo $oen['eventname'] ;


when the row does not have and apostrophe's, it prints like a charm, but if it does, nothing.g the posting above:

Code: Select all

echo $oen['eventname'] ;
when the row does not have and apostrophe's, it prints like a charm, but if it does, nothing.and apostrophe's, it prints like a charm, but if it does, nothing.]

when the row does not have and apostrophe's, it prints like a charm, but if it does, nothing. posting above:

Code: Select all

echo $oen['eventname'] ;
when the row does not have and apostrophe's, it prints like a charm, but if it does, nothing.strophe's, it prints like a charm, but if it does, nothing.1111;'eventname'] ;


when the row does not have and apostrophe's, it prints like a charm, but if it does, nothing.

when the row does not have and apostrophe's, it prints like a charm, but if it does, nothing.he's, it prints like a charm, but if it does, nothing.entname'] ;


when the row does not have and apostrophe's, it prints like a charm, but if it does, nothing.php]

when the row does not have and apostrophe's, it prints like a charm, but if it does, nothing.7ebe7]
echo $oen['eventname'] ;


when the row does not have and apostrophe's, it prints like a charm, but if it does, nothing.e:

Code: Select all

echo $oen['eventname'] ;
when the row does not have and apostrophe's, it prints like a charm, but if it does, nothing.ventname'] ;


when the row does not have and apostrophe's, it prints like a charm, but if it does, nothing.t prints like a charm, but if it does, nothing.7ebe7]
echo $oen['eventname'] ;


when the row does not have and apostrophe's, it prints like a charm, but if it does, nothing.php]
echo $oen['eventname'] ;


when the row does not have and apostrophe's, it prints like a charm, but if it does, nothing.egarding the posting above:

Code: Select all

echo $oen['eventname'] ;
when the row does not have and apostrophe's, it prints like a charm, but if it does, nothing.g above:

Code: Select all

echo $oen['eventname'] ;
when the row does not have and apostrophe's, it prints like a charm, but if it does, nothing.097ebe7]
echo $oen['eventname'] ;


when the row does not have and apostrophe's, it prints like a charm, but if it does, nothing.ove:

Code: Select all

echo $oen['eventname'] ;
when the row does not have and apostrophe's, it prints like a charm, but if it does, nothing.
echo $oen['eventname'] ;


when the row does not have and apostrophe's, it prints like a charm, but if it does, nothing.
User avatar
Burrito
Spockulator
Posts: 4715
Joined: Wed Feb 04, 2004 8:15 pm
Location: Eden, Utah

Post by Burrito »

you might try escaping the string with mysql_real_escape_string().

also wouldnt' be a bad idea to create the query outside of the function and then echo it. a lot of times it turns out looking much differen't that you anticipated.

8O
imstupid
Forum Commoner
Posts: 84
Joined: Fri Feb 18, 2005 1:24 pm

Post by imstupid »

thanks burrito-
works great. is this mysql_real_escape_string something I should get used to using on a regular basis, especially if I don't know whether or not an user will enter something with special characters?
User avatar
Burrito
Spockulator
Posts: 4715
Joined: Wed Feb 04, 2004 8:15 pm
Location: Eden, Utah

Post by Burrito »

yup 8O
timvw
DevNet Master
Posts: 4897
Joined: Mon Jan 19, 2004 11:11 pm
Location: Leuven, Belgium

Post by timvw »

It only lasts untill you start using adodb and you switch to Qstr();


After that you'll discover prepared statements and parameter binding and write
"SELECT * FROM foo WHERE bar=?" ;)
Post Reply