5
Sirs,
I am working with tabs in Jquery. I have a page called inclu_server.php where I do the Insert in the database of as many servers as I want. I need that after clicking the button next the amount of tabs on the page be the same as the amount of records that were entered on the previous page. That I even managed to do with the code below:
<div id="tabs">
<ul>
<?php
do {
?>
<li><a href="#tabs-<?php echo $row_menu_servidor['host_servidor']?>"><?php echo $row_menu_servidor['host_servidor']?></a></li>
<?php
} while ($row_menu_servidor = mysql_fetch_assoc($menu_servidor));
$rows = mysql_num_rows($menu_servidor);
if($rows > 0) {
mysql_data_seek($menu_servidor, 0);
$row_menu_servidor = mysql_fetch_assoc($menu_servidor);
}
?>
</ul>
My problem now is that I need the content of this DIV or TAB/ABA to be dynamic as well. From what I’m imagining, I need to declare that for each
<li><a href="#tabs-<?php echo $row_menu_servidor['host_servidor']?>"><?php echo $row_menu_servidor['host_servidor']?></a></li>` a página inclua uma DIV com o conteúdo `<div id="tabs-ndcingmgm001">
<div id="id_solic"><div style="position: absolute; margin-left:10px; margin-top:-10px; width:100px; height: 10;"><br/>
<h4>ID Solicitação<br>
<form name="form1" method="post" action="">
<input name="id_solic" id="id_solic" type="text" value="<?php echo $_POST['id_solic'];?>" size="5" readonly="readonly">
<br><br>
</form>
</div>
</div>
</div>
I believe I have to make the ID of this DIV content dynamic, according to the amount of query records passed above.
I hope I was able to explain it clearly.
deFreitas, I understood this but I’m taking href according to the query I executed. It can have 10 records as it can have 2. I need the tabs ID to be equal to the one placed on href by variable. <a href="#tabs-<? php echo $row_menu_server['host_server']? >"><? php echo $row_menu_server['host_server']?>
– Rodrigo Biaggio