GoFuckYourself.com - Adult Webmaster Forum

GoFuckYourself.com - Adult Webmaster Forum (https://gfy.com/index.php)
-   Fucking Around & Business Discussion (https://gfy.com/forumdisplay.php?f=26)
-   -   I need a php whiz smarter than me to look at this code. (https://gfy.com/showthread.php?t=473906)

Adult Site Traffic 05-29-2005 07:12 AM

I need a php whiz smarter than me to look at this code.
 
I don't understand why this gives errors. I have used it before in .php hosted gallery pages etc.

PHP Code:

{
      echo "<tr><td align=\"center\" colspan=\"".(COL_CATEG * 2)."\"><a href=\"".$PHP_SELF."?categ=".$categ."&sta=".($sta - $show)."\"><img border=\"0\" src=\"http://site.com/members/images/back.jpg\" style=\"border: 1px solid #FF3399\" alt=\"Previous page of members area content\" width=\"150\" height=\"45\"></a>
&nbsp;nbsp;<a href=\"<?=$_GET["categ"]?>_next.php\"><img border=\"0\" src=\"http://site.com/members/images/next.jpg\" style=\"border: 1px solid #FF3399\" alt=\"Next page of members area content\" width=\"150\" height=\"45\"></a></td></tr>";

This is the code giving the error:
PHP Code:

<a href=\"<?=$_GET["categ"]?>_next.php\">

I have also used:
PHP Code:

<a href=\"<?=$_GET[\"categ\"]?>_next.php\">

This is the error:
Parse error: parse error, unexpected '\"', expecting T_STRING or T_VARIABLE or T_NUM_STRING

Ideas?

Thanks.

spacemonk 05-29-2005 07:14 AM

you forgot an echo

AcidMax 05-29-2005 07:16 AM

Looks to be

<a href="<?=$_GEThahaha91;"categ"]?>_next.php\">

Look at the categ... you have ;" instead of ;\" like your other example shows. Hard to know without seeing the code work etc, but looking at your other example and based on the error its missing the \ which is an escape.

Veterans Day 05-29-2005 07:17 AM

contact silvertab he is php ninja, tell him I sent ya. Hes a good friend of mine. I wont fuck with noone else 94586959

Adult Site Traffic 05-29-2005 07:20 AM

Where?

What makes it any different? The only code in question is:

href=\"<?=$_GET["categ"]?>_next.php\"
vs
href=\"next.php\"

http://adult-site-traffic.com/phpcode.htm is the real code. Board fucked it up.

.

Adult Site Traffic 05-29-2005 07:24 AM

Quote:

Originally Posted by AcidMax
Looks to be

<a href="<?=$_GEThahaha91;"categ"]?>_next.php\">

Look at the categ... you have ;" instead of ;\" like your other example shows. Hard to know without seeing the code work etc, but looking at your other example and based on the error its missing the \ which is an escape.

Ok, I tried this:
href=\"<?=$_GET[\"categ\"]?>_next.php\"

and this:
href=\"<?=$_GET["categ"]?>_next.php\"

But I should have this instead ?
href=\"<?=$_GET[\"categ"]?>_next.php\"

Thank you.

.

ssp 05-29-2005 07:27 AM

Why don't you just use this:

<a href=\"" . $_GET["categ"] . "_next.php\">

spacemonk 05-29-2005 07:28 AM

Quote:

Originally Posted by Adult Site Traffic
Ok, I tried this:
href=\"<?=$_GET[\"categ\"]?>_next.php\"

and this:
href=\"<?=$_GET["categ"]?>_next.php\"

But I should have this instead ?
href=\"<?=$_GET[\"categ"]?>_next.php\"

Thank you.

.

You forgot an echo

href=\"<? echo $_GET["categ"] ?>_next.php\"

Juicy D. Links 05-29-2005 07:32 AM

echo 5<> output echo roger over

print <> word

Trafficbrokercom 05-29-2005 07:38 AM

He did not forget an echo the '=' equals "echo" in this case ..

the problem is a little bit more complex , what you are trying to do is basically starting a second php instance within an existing one (<? ... <?)

so change this code:

Code:

<a href="<?=$_GET["categ"]?>_next.php\">
to

Code:

<a href=\"" . $_GET["categ"] . "_next.php\">
the two quotation marks after the href are very important btw ..

Adult Site Traffic 05-29-2005 07:42 AM

Quote:

Originally Posted by ssp
Why don't you just use this:

<a href=\"" . $_GET["categ"] . "_next.php\">

YOU are fucking smart :thumbsup

.

Adult Site Traffic 05-29-2005 07:43 AM

Quote:

Originally Posted by Juicy D. Links
echo 5<> output echo roger over

print <> word

LOL Juicy :)

format C:\

ssp 05-29-2005 08:01 AM

Glad I could help you out. :)

AcidMax 05-29-2005 10:35 AM

Sorry I guess the shit was encoded when you put it on here, so it looked like a " was unescaped. Glad you got it sorted out.


All times are GMT -7. The time now is 05:06 AM.

Powered by vBulletin® Version 3.8.8
Copyright ©2000 - 2025, vBulletin Solutions, Inc.
©2000-, AI Media Network Inc123