www.webdeveloper.com
Results 1 to 9 of 9

Thread: This Is So Annoying - How Can I Do This

  1. #1
    Join Date
    Apr 2008
    Posts
    36

    This Is So Annoying - How Can I Do This

    Okay i've been updating my site and making it easier to update which has worked however i have one huge major massive problem that i cannot solve.

    On my sites front page it pulls in the data from my blog for the updates section, however the text is formatted fine in the blog page but on the sites front page it just all goes together it is missing the necessary p or br tags, so i have to put to br tags into the blog page.

    This is annoying because if i forget to do it, it makes the front of my site look a real mess.

    Here is an example of the text & how it appears

    update one, etc etc

    update two etc etc

    Because the tags arent their they just go togther.

    Can someone please tell me how i can format this in css so it adds the line breaks at the end of a sentence, and doesnt look a mess

  2. #2
    Join Date
    Nov 2003
    Location
    Jerryville, Tejas
    Posts
    11,715
    The blog must be taking the raw text and marking it up on the fly. I suspect you'll need to do that for your front page. Maybe you can call the blog function that does it.
    "Debugging is twice as hard as writing the code in the first place. Therefore, if you write the code as cleverly as possible, you are, by definition, not smart enough to debug it." Brian W. Kernighan

  3. #3
    Join Date
    Apr 2008
    Posts
    53
    Try adding a <div> </div> container within the html of you're blog
    and apply a width to it (with css), so that that text is bound to that container.

    If you still have trouble, give as a link to you're blog, we might be available
    take a look and advice better.

  4. #4
    Join Date
    Apr 2008
    Posts
    36
    Hi thanks for replying i really appreciate it.

    This is the blog page with the site updates on

    http://www.atlantisarchive.com/journal/?page_id=281

    I use a php script which pulls this information to the sites front page which works great no problems there.

    Its just the way its formatted i just cant figure out how to get it to display properly.

    If i dont add to brs in the blog at the end of each sentence it all just goes together on the front page. Very annoying indeed.

    Its probably a lazy way of updating things but if im not at my laptop i need to a quick way to make a post about new updates, etc.

  5. #5
    Join Date
    Jan 2005
    Location
    Frankfort, KY, USA
    Posts
    6,167
    Your container doesn't have a width set, so it's inheriting the width of the parent, set at 710px. Set a width for either "content" or "entry."
    FYI
    * My screen resolution is set at 1680x1050
    * I'm accessing your site through a T1 line
    * I'm probably viewing it using Firefox (unless browser is specified)

  6. #6
    Join Date
    Apr 2008
    Posts
    53
    Did you resolve your problem?

  7. #7
    Join Date
    Apr 2008
    Posts
    36
    This is how the data is output through the script from the blog

    HTML Code:
    Spoiler information added for <a title="Interact with other fans in the forum" href="/talk/viewforum.php?f=33">Season Five episode The Lost Tribe</a><br /><br />
    
    We have added new merchandise to the <a title="Buy Stargate SG1, Stargate Atlantis and more, merchandise in the online store" href="/store/">Online Store</a><br /><br />
    
    New Welcome paged launched<br /><br />
    
    We are pleased to announce the launch of our new <a title="Register your free @atlantisarchive.net email address" href="/?p=email/index">Free E-mail</a> service<br /><br />
    
    Additional spoiler information added for <a title="Interact with other fans in the forum" href="/talk/viewforum.php?f=33">Season Five episode The Queen</a><br /><br />
    
    <a title="Find out everything you need to know, about Season Five" href="/?p=onscreen/season5/index">Season Five</a> episode descriptions updated<br /><br />
    
    We have expanded our <a title="Subscribe to any of our RSS feeds and be kept constantly up to date, on all the latest events with the Atlantis Archive and the Stargate Universe" href="/?p=services/rss">RSS Feeds</a> to include all the latest television schedule information<br /><br />
    
    5gb free email service coming soon<br /><br />
    
    Watch the Stargate Continuum <a title="Video footage provided by MGM, Home of the Official Stargate Atlantis Website" href="javascript:Popup('/pop-up/?p=movies/continuum3');">Official Teaser Trailer</a><br /><br />
    
    We have just upgraded our <a title="Learn how to integrate Atlantis Archive news feeds into your web site" href="/journal/?page_id=225">News Feed Integration</a> service for other web site owners<br /><br />
    
    Your feedback is needed, <a title="Leave your views and opinions regarding the Atlantis Archive, in our guest book" href="/talk/viewtopic.php?f=27&amp;t=95">leave your comments and suggestions</a>
    Without the line breaks it just goes into a mess on the sites front page. I tried the div class thing with the width but it didnt make a difference as the output is still the same without br tags

  8. #8
    Join Date
    Apr 2008
    Posts
    36
    Without the br tags it just looks like this on the output page

    Link straight to the test page http://www.atlantisarchive.com/?p=test

    Link to the test blog entry http://www.atlantisarchive.com/journal/?page_id=287

    (i've set up a secondary page within the blog, so i can test things in an unlive environment for the time being)

    Obviously the links arent their in that text above
    Last edited by aduk85; 05-08-2008 at 07:02 AM.

  9. #9
    Join Date
    Apr 2008
    Posts
    36
    Those pages in my previous post dont work i've deleted them.

    I think i am going to give up and try an alternative method. It doesnt appear there is anything that can be done with CSS its a php problem one that i cant figure out.

    Thank you for your help though i really appreciate it

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
HTML5 Development Center



Recent Articles