Jump to content

[SOLVED] Horizontal repeat regions


Zergman

Recommended Posts

I can't seem to figure out how to repeat my data horizontally instead of vertically.

 

I tried searching google, but most of the results are for a dreamweaver extension to do it.  Can't find out how to do it by hand.

 

Here is my query.  Pardon my newbish skills, still learning :)

<?php

mysql_select_db($database_cntrackanator, $cntrackanator);
$query_rssql = "SELECT * FROM templates_categories WHERE uname = '$username' ORDER BY category_name";
$rssql = mysql_query($query_rssql, $cntrackanator) or die(mysql_error());
$row_rssql = mysql_fetch_assoc($rssql);
$totalRows_rssql = mysql_num_rows($rssql);
    echo $row_rssql['category_name'];

?>

 

So how can I get this to loop vertically instead of down?

Link to comment
Share on other sites

k, that is pretty wicked, im really going to have to read up on this more.

 

One last thing that will solve this issue.

 

I want to make the output link to the same variable name as whats shown.

 

This is what I have so far but not doing something right here.

<?php

mysql_select_db($database_cntrackanator, $cntrackanator);
$query_rssql = "SELECT * FROM templates_categories WHERE uname = '$username' ORDER BY category_name";
$rssql = mysql_query($query_rssql, $cntrackanator) or die(mysql_error());
$row_rssql = mysql_fetch_assoc($rssql);
$totalRows_rssql = mysql_num_rows($rssql);
while($row_rssql = mysql_fetch_assoc($rssql))
echo '<div class="cat_name">[<a href="">',$row_rssql['category_name'],"</a>]</div>\n ";

?>

 

I want to use the same $row_rssql['category_name'] in the hyperlink but can't get the proper syntax right.

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.