Jump to content

code problem..please help. i'm a newbie! :)


thebeing

Recommended Posts

Hello! i'm having some problem with some php code...

the problem :
i get this error...

[code]Notice: Undefined variable: showCategories in c:\program files\easyphp1-8\www\joke_site\templates\MainHeader.php on line 86[/code]


for this code...


[quote] <?=$showCategories?>[/quote]


can anyone help me, please? can anyone tell me, what must i write in the code to make it work?

thnx in advance!
Link to comment
Share on other sites

hello, and thnx for your reply...

i thought of inserting a bigger part of the code into my post...but most of it would have been irrelevand...

however...if ur willing to help me (please, be!), here's a bigger part of the code...

http://tinyurl.com/ewcrq

note : the memberblock thinggie works... but the categories and the buttonbanner don't...

this is a part from a script i bought from someone over the net...and now he(or she...) doesn't answe when i try to contact him/her... :(
Link to comment
Share on other sites

i did as you said...

from [code] <?=$showCategories?>[/code] i made [code] <? $showcategories='showcategory.php' ?> [/code] ...but, in showcategory.php i have these errors :
[code] Notice: Undefined index: CategoryID in c:\program files\easyphp1-8\www\e_site\showcategory.php on line 6

Notice: Undefined index: CategoryID in c:\program files\easyphp1-8\www\e_site\showcategory.php on line 12[/code]

This is how line 6 and 12 look in the php :
line 6
[code]
$q1 = "select CategoryName from dd_categories where CategoryID = '$_GET[CategoryID]'  ";[/code]
line 12
[code]
$MainQuery = "select * from dd_items where ItemCategory = '$_GET[CategoryID]' and ItemStatus = 'approved' "; [/code]

it also gives the same errors for the connect.php, which is the... connect config file...
two errors 1. [code][b]Notice: Undefined variable: categories in c:\program files\easyphp1-8\www\e_site\conn.php on line 42[/b][/code]
and the 2. Notice: Undefined index: CategoryID in c:\program files\easyphp1-8\www\joke_site\conn.php on line 44...the code in the connect php is :
[code]
line 42    $categories .= "<a class=CatLinks href=\"ShowCategory.php?CategoryID=$ac[CategoryID]\">$ac[CategoryName] ($ain[0])</a><br>\n\t\t\t";

line 44   if($_GET['CategoryID'] == $ac['CategoryID'])[/code]

...can you still guide me? please?
Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.