TP-Docs
HTML5 Icon HTML5 Icon HTML5 Icon
TP on Social Media

Recent

Welcome to TinyPortal. Please login or sign up.

Members
  • Total Members: 3,966
  • Latest: safir45
Stats
  • Total Posts: 195,982
  • Total Topics: 21,320
  • Online today: 468
  • Online ever: 8,223 (February 19, 2025, 04:35:35 AM)
Users Online
  • Users: 0
  • Guests: 509
  • Total: 509

how to remove the "first" blank line in an article

Started by AgO, January 27, 2007, 01:05:58 PM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

AgO

i have posted in the German forum first but nobody answers me.
so i try it in English.

when i create a new article and don't want to show the author and the date on top of the article, then an ugly blank line instead of the author/date info shows up.
Is there a way to remove this line in this constellation (no author/no date)?

it would be usefull by inserting ext. scripts with different background-colors.

hope you have understand me... 



JPDeni

It would help if we could see an example of what you mean.

Lesmond

I think this is what he means <div style="line-height: 1.3em;">  its dealt with in css I think

AgO

take a look @ http://www.taralaw.de/index.php?page=17

i mean the blank space between the article-title and the lightgrey background from the gb-script.
normally the date of creation and the author appears there, but if you have disabled this 2 features its looks like my gb-article.
i have tried some modifications in the css-file but without success.
maybe there is a <br> somewhere hidden in the entire code, but i couldnt find it.

JPDeni

Yes, there is a line-break in there:


   <body style='margin: 0px; padding: 0px; background-color: #eeeeee; scrollbar-base-color:#FF0000; scrollbar-3dlight-color:#FFFFEE; scrollbar-arrow-color:#444444; scrollbar-darkshadow-color:#999999; scrollbar-face-color:#EEEEEE; scrollbar-highlight-color:#FFFFFF; scrollbar-shadow-color:#BBBBBB; scrollbar-track-color:#D8D8D8'>

    <br><table border="0" width="100%" cellspacing="0" cellpadding="0">
    <tr>
      <td align="center" valign="top">
<span class='vgbamenu'>Zeige Eintr&auml;ge</span><span class='vgbseperator'> | </span>
<a onfocus="if(document.all) this.blur()" href='index.php?n5c840=0' class='vgbmenu'>Eintrag ins G&auml;stebuch</a><span class='vgbseperator'> | </span> <a onfocus="if(document.all) this.blur()" href='index.php?r9c7d6=0' class='vgbmenu'>Statistiken</a><span class='vgbseperator'> | </span> <a href='#' onclick='var w=window.open("ad"+"min.php","Admin");w.focus()' class='vgbmenu'>Admin</a><br /><br />


Look at the code just before the < table > tag and you'll see it.

I don't know where it is in your code, but it's there in the source.

My suggestion is that, if you are trying to find basic formatting structure in articles and blocks, you start with very simple content so that it's easier to tell the difference between the TP formatting and the formatting that is in the articles. I would suggest that you create a test article that has no formatting within it at all, but only text and see how that looks. Then gradually add formatting to your test article so you can see where the problem arises.

AgO

i have made a testarticle with only text ("OOO") in it.

thats the source from the article (the code that my browser gives out)
<td width="100%" align="left" valign="top" style="padding-top: 10px; padding-bottom: 10px;">
<table cellpadding="0" cellspacing="0" border="0" width="100%" style="table-layout: fixed;">
<tr>
<td valign="top">
<div class="tborder" style="margin-bottom: 2px; ">
<div style="padding: 3px 6px 3px 6px;" class="titlebg"> <a href="http://www.taralaw.de/index.php?page=20"><b>
test</b></a></div>
<table width="100%" cellpadding="0" cellspacing="0">
<tr>
<td valign="top"  class="windowbg2" style="padding: 4px;"><br />
<div style="_height: 1%; overflow: auto; ">
<div style="line-height: 1.3em; "><p>OOO</p>
</div>
      </div>
</td>
</tr>
<tr>
<td   class="windowbg2">
          <div class="smalltext" style="margin: 2ex 1ex 1ex 1ex;"><a href="http://www.taralaw.de/index.php?action=tpadmin;sa=editarticle20">
[Artikel ändern]</a>
          <a href="http://www.taralaw.de/index.php?action=tpadmin;sa=editarticle20;visualopts">
[Optionen bearbeiten]</a>
          </div></td>
</tr>
</table></div></td>
</tr>
</table></td>


You can see the "br /" tag in this line
<td valign="top"  class="windowbg2" style="padding: 4px;"><br />

this causes the blank line and it must be located somewhere in the tp-code.
i have copied the code to frontpage and after i removed the "br /" thing from the code all looks good.
this empty line is made by the tinyPortal and i think the only way to remove the line is to edit a tp-sourcefile.

as i said i have searched a long time in all suspicious files but couldnt find anything.

my hope was you can give an order like:
look in file xy on line x there you can find the evil tag.

JPDeni

<quote>You can see the "br /" tag in this line</quote>
I'm afraid I can't see it, because you haven't given me a link to the article.

AgO

Yo i figured it out.

edit: no that was bullshit.

can someone other code (in TPortal.template.php) something like:

if option1 or option2 or optionX (all the options that could appear in top of an article like author/date/comments...) = true (or whatever)
echo'[the options] and [the article]'
else
echo'[only the article]'

??

This website is proudly hosted on Crocweb Cloud Website Hosting.