imgcreate 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
michael_bates
Forum Newbie
Posts: 2
Joined: Mon Nov 22, 2010 6:05 am

imgcreate question

Post by michael_bates »

Hi i have created a graph using the imgcreate() fuction. The graph works fine when on its own page i was looking for some help on how to get it onto another page, any help would be appriciated thanks.
adil
Forum Newbie
Posts: 6
Joined: Wed Oct 13, 2010 3:46 am

Re: imgcreate question

Post by adil »

<img src="Image.php" >
michael_bates
Forum Newbie
Posts: 2
Joined: Mon Nov 22, 2010 6:05 am

Re: imgcreate question

Post by michael_bates »

Hey thanks for the reply that worked. But now i am facing another problem.

My graph is shown by image and then below has a link to view it on another page.
So the problem i am facing is when going to graph.php i pass the variables through the url by doing.

Code: Select all

echo "<a href='graph.php?mark1=$mark1&mark2=$mark2&mark3=$mark3&mark4=$mark4'>Click here</a>";
However when doing

Code: Select all

<img src"graph.php?mark1=$mark1&mark2=$mark2&mark3=$mark3&mark4=$mark4"/>
It does not show the graph with the bars going up with the correct values. In actual fact it places the values which should be an integer to $mark1, $mark2, $mark3 and $mark4.

Does anyone have any solution to how i can acctually pass the value to this page and get the graph to draw correctly when using <img src>

Any help would be appricated
Thanks MIchael.
Post Reply