?
Solved

shift text right (or center under picture table) in cgi script

Posted on 2011-03-08
2
Medium Priority
?
331 Views
Last Modified: 2013-12-25
I'm using the code below but I want to center the text "Photograph by name" under the picture it is currently left aligned from what I can see. Also, I could shift it to the right a few characters but I am not sure how to do that

print "</table>\n";
print "<p>&nbsp;</p>\n";
print "<table align=center width=800px cellpadding=15 cellspacing=0 id=gray_top_border>\n";
print "<tr>\n";
print "<td>\n";
print "<h3 class=no_margin-top><a href=/path/fcst/index.cgi>Vog Forecast Discussion</a></h3>\n";
print "<p><a href=/path/index.cgi><img src=/path/image.jpg alt=\"Big Island logo image\" width=220 height=220 /></a></p>\n";
print "<p><em>Photograph by Name</em></p>\n";
print "<p><a href=/path2/index.cgi>Daily discussion</a> that explains in words the expected distribution of vog concentrations over the Hawaiian Islands as a result of the interaction of the volcanic emissions and the current and forecast weather.  </p>\n";
print "</td>\n";
print "<td>\n";
0
Comment
Question by:libertyforall2
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
2 Comments
 
LVL 48

Accepted Solution

by:
Tintin earned 2000 total points
ID: 35079854
Much easier to read/write and maintain if you get rid of all those individual print statements.

Try this:

print <<EOF;
</table>
<p>&nbsp;</p>
<table align=center width=800px cellpadding=15 cellspacing=0 id=gray_top_border>
<tr>
<td>
<h3 class=no_margin-top><a href=/path/fcst/index.cgi>Vog Forecast Discussion</a></h3>
<p><a href=/path/index.cgi><img src=/path/image.jpg alt="Big Island logo image" width=220 height=220 /></a></p>
<p align="center"><em>Photograph by Name</em></p>
<p><a href=/path2/index.cgi>Daily discussion</a> that explains in words the expected distribution of vog concentrations over the Hawaiian Islands as a result of the interaction of the volcanic emissions and the current and forecast weather.</p>
</td>
<td>
EOF

Open in new window

0
 

Author Closing Comment

by:libertyforall2
ID: 35404726
Great!
0

Featured Post

Are You Using the Best Web Development Editor?

The worlds of web hosting and web development are constantly evolving. Every year we see design trends change, coding standards adapt and new frameworks/CMS created. With such a quick pace of change it’s easy to get lost trying to keep up.

See if your editor made the list.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Although a lot of people devote their energy toward marketing for specific industries, there are some basic principles that can be applied to any sector imaginable. We’ll look at four steps to take and examine how those steps were put into action fo…
When it comes to security, close monitoring is a must. According to WhiteHat Security annual report, a substantial number of all web applications are vulnerable always. Monitis offers a new product - fully-featured Website security monitoring and pr…
In this fifth video of the Xpdf series, we discuss and demonstrate the PDFdetach utility, which is able to list and, more importantly, extract attachments that are embedded in PDF files. It does this via a command line interface, making it suitable …
In a recent question (https://www.experts-exchange.com/questions/29004105/Run-AutoHotkey-script-directly-from-Notepad.html) here at Experts Exchange, a member asked how to run an AutoHotkey script (.AHK) directly from Notepad++ (aka NPP). This video…
Suggested Courses

771 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question