Ravens PHP Scripts: Forums
 

 

View next topic
View previous topic
Post new topic   Reply to topic    Ravens PHP Scripts And Web Hosting Forum Index -> v2.4 RN Issues
Author Message
andylau
Hangin' Around



Joined: Jul 05, 2006
Posts: 27

PostPosted: Sat Jan 02, 2010 9:37 am Reply with quote

hope this is the right place.

i got problem with story text and extended text

after post there are some line between story text and extended text after read more?
may be -> br br   between those

help thanks.
 
View user's profile Send private message
Palbin
Site Admin



Joined: Mar 30, 2006
Posts: 2583
Location: Pittsburgh, Pennsylvania

PostPosted: Sat Jan 02, 2010 10:12 am Reply with quote

Line 113 of /modules/News/articles.php
Code:


   $bodytext = $hometext . '<br /><br />' . $bodytext;

_________________
"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. 
View user's profile Send private message
andylau







PostPosted: Sat Jan 02, 2010 4:57 pm Reply with quote

wow. thanks. the 2lines of <br> gone but still one more line between, it look likes &nbsp <- i use simpleblue theme.

please help thanks.
 
Palbin







PostPosted: Sat Jan 02, 2010 6:58 pm Reply with quote

Guess I should have posted what to change it to Smile

Code:


$bodytext = $hometext . $bodytext;
 
andylau







PostPosted: Sun Jan 03, 2010 6:23 am Reply with quote

thanks. now i found something in the source code there are automatic <p></p>
between them how to get rid of it ?

what i did in manual from source i remove </p> from story text and <p> from extended text and keep one br . any idea to remove that thanks.
 
nuken
RavenNuke(tm) Development Team



Joined: Mar 11, 2007
Posts: 2024
Location: North Carolina

PostPosted: Sun Jan 03, 2010 7:39 am Reply with quote

That is being place there by the nukeWYSIWYG editor.

_________________
Only registered users can see links on this board! Get registered or login! 
View user's profile Send private message Send e-mail Visit poster's website
andylau







PostPosted: Sun Jan 03, 2010 8:25 pm Reply with quote

any help to remove it ?
 
Palbin







PostPosted: Sun Jan 03, 2010 8:53 pm Reply with quote

Are you sure there isn't a blank line at the beginning of the "extended text"? Edit the story and look because I think that is your problem.
 
Palbin







PostPosted: Sun Jan 03, 2010 8:54 pm Reply with quote

Also check the end of the first part for a blank line.
 
andylau







PostPosted: Sun Jan 03, 2010 9:12 pm Reply with quote

i start a new one . i just type test in story text and some text in extended text and check in source i found <p></p> those in there automatic . Sad
any idea ?
 
nuken







PostPosted: Sun Jan 03, 2010 11:10 pm Reply with quote

The easiest way to do what you want to do is to change the line you edited earlier
Code:
$bodytext = $hometext . $bodytext; 


to

Code:
$bodytext = $bodytext; 


and just retype the hometext into the top of the bodytext. This would be more like using the home text as a preview of the article and use the body text as the actual article.
 
andylau







PostPosted: Mon Jan 04, 2010 5:22 am Reply with quote

well still have to retype ?
how about disable <p> and </p> in source ?
 
montego
Site Admin



Joined: Aug 29, 2004
Posts: 9457
Location: Arizona

PostPosted: Mon Jan 04, 2010 6:56 am Reply with quote

I don't think this belongs in this forum. Which version of RN are you using andylau? Thanks.

_________________
Only registered users can see links on this board! Get registered or login!
Only registered users can see links on this board! Get registered or login! 
View user's profile Send private message Visit poster's website
nuken







PostPosted: Mon Jan 04, 2010 7:02 am Reply with quote

The <p> tags are generated by the wysiwyg editor. You are using two separate instances of the editor so you will have the tags there unless you change the way the fckeditor closes text. This could cause all kind of issues with regard to how the text is rendered on the site.

What I suggested was when you post a story in the news, type what you want displayed on the front page in the Story Text text area and type what you want displayed on the articles page in the Extended Text text area. The $hometext is the Story Text and the $bodytext is the Extended Text. If you remove the $hometext from the code mentioned above, you will be left with only the Extended Text (if used) on the article view which will be formated with out the extra <p> tags that are causing the unwanted spaces. If you do not use the Extended Text, the articles view will be the Home Text.
 
andylau







PostPosted: Mon Jan 04, 2010 7:53 am Reply with quote

i use RavenNuke_v2.40.00 . nuken i can't use the code like u say. otherwise i lost the home text when they click on readmore...
 
nuken







PostPosted: Mon Jan 04, 2010 7:54 am Reply with quote

Another way would be to change the <p> tag in your themes css to something like this

Code:
p{margin-top: 0; padding-top: 0;} 
 
Palbin







PostPosted: Mon Jan 04, 2010 8:58 am Reply with quote

I tested this on my site you should not be getting a <p> </p> unless you have a blank line. The wysiwyg editor does not add <p> tags to the beginning or end unless you do.
 
nuken







PostPosted: Mon Jan 04, 2010 10:51 am Reply with quote

Edit: You are correct Palbin. My bad.
 
andylau







PostPosted: Mon Jan 04, 2010 4:57 pm Reply with quote

i do just write some text but if i look in source there are <p> </p> everyline there.
can i post my site here u can check ?
 
Palbin







PostPosted: Mon Jan 04, 2010 11:50 pm Reply with quote

Yes every line has <p> tags. I thought you where talking about have "<p> </p>" in between your home and body text. If you do you have a blank line. If you are talking about removing it in general, not sure why you would be, that is not possible.
 
andylau







PostPosted: Tue Jan 05, 2010 3:17 am Reply with quote

home text
<p>testing01</p>

Extended text
<p>testing02</p>

it's coming out like this:

testing01

testing02

i dun want it a line break them in between when i've remove <br><br> from 113 line of the article.php

so need to be

like this:

Home text
<p>testing01

Extended text
testing02</p>

and one <br> in article.php line 113

so it will come out like this

testing01
testing02




when i was using phpnuke never got something like that . any idea for that?
 
nuken







PostPosted: Tue Jan 05, 2010 7:07 am Reply with quote

I didn't give you the complete css to remove the space, sorry. Try using this in your themes style.css.
Code:
p{margin-top: 0; padding-top: 0; margin-bottom: 0; padding-bottom: 0;} 
 
andylau







PostPosted: Wed Jan 06, 2010 12:56 am Reply with quote

i've try. but still not work Sad thanks anyway. i have to do manua.

well can u give me any idea again about remove
<p> </p> in source from the editor ?
 
andylau







PostPosted: Thu Jan 07, 2010 1:18 am Reply with quote

hi again. now it's working. kewl thanks for the clue nuken
 
Guardian2003
Site Admin



Joined: Aug 28, 2003
Posts: 6799
Location: Ha Noi, Viet Nam

PostPosted: Mon Jan 11, 2010 11:04 am Reply with quote

The wysiwyg editor automatically 'cleans' the formatting to show paragraphs. To stop it creating paragraphs use SHIFT + ENTER in the editor for a new line, this will force the editor to use <BR /> instead of paragraphs.
 
View user's profile Send private message Send e-mail
Display posts from previous:       
Post new topic   Reply to topic    Ravens PHP Scripts And Web Hosting Forum Index -> v2.4 RN Issues

View next topic
View previous topic
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You can attach files in this forum
You can download files in this forum


Powered by phpBB © 2001-2007 phpBB Group
All times are GMT - 6 Hours
 
Forums ©