hi all,

i wanted passe multiple variable to php file from get methode

here is the code

<div onmouseover="show(document.getElementById('link<?php echo $cmId.$poId?>'));"     onmouseout="hide(document.getElementById('link<?php echo $cmId.$poId?>'));">

 <form> <?php echo $row['comment_cm']?><br><a href="editComment.php?        
 var1=$cmId&var2=$poId" id="link<?php echo $cmId.$poId?>">Edit</a>                
</form>
       </div>

Recommended Answers

All 3 Replies

Member Avatar for diafol

So what's the problem? Is your issue js or php? I don't understand why you have this code inside a form. You don't need a form here??

What is your issue?
Want to send multiple parameters via hyperlink?
For that Change your hyper link as

<a href="editComment.php?var1=<?php echo $cmId?>?var2=<?php echo $poId ?>" id="link<?php echo $cmId.$poId?>">Edit</a>

use the & for multiple gets not the ? to seperate them

<a href="editComment.php?var1=<?php echo $cmId?>&var2=<?php echo $poId ?>" id="link<?php echo $cmId.$poId?>">Edit</a>

so on the next page you use
$_GET
$_GET

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.