Jump to content


Unreal Portal 2.2.0 Cut Off The News With No bugs!!!


  • You cannot reply to this topic
16 replies to this topic

#1 redalert19882000

    Advanced Member

  • Members
  • PipPipPip
  • 54 posts

Posted 22 December 2006 - 08:05 AM

Open sources/action_public/uportal.php

Find: In News not Latest news!!! Be careful

while($fetch = $this->ipsclass->DB->fetch_row($query))
			{


Add below:

$fetch[post] = substr($fetch[post], 0, 400)."...";



Change tha number 400 for yours choise!

Now this code cuts off the news after 400 characters!

Open cache/lang_cache/*/lang_uportal.php

Find:

'view_comments'		=>	"View Comments",



Replace With:

'view_comments'		=>	"More",


#2 armyofone

    Newbie

  • Members
  • Pip
  • 1 posts

Posted 23 December 2006 - 02:53 PM

Thanks! I really wanted this one. Works greate.

#3 cinek

    Newbie

  • Members
  • Pip
  • 4 posts

Posted 23 December 2006 - 05:27 PM

great :D thanks

EDIT:

it should be:

Open cache/lang_cache/lang_uportal.php

Find:

'view_comments' =>  "................";




Replace With:

'view_comments' =>  "More",


;)

#4 redalert19882000

    Advanced Member

  • Members
  • PipPipPip
  • 54 posts

Posted 24 December 2006 - 04:23 AM

View Postcinek, on Dec 23 2006, 06:27 PM, said:

great :D thanks

EDIT:

it should be:

Open cache/lang_cache/lang_uportal.php

Find:

'view_comments' =>  "................";

Replace With:

'view_comments' =>  "More",

;)



E???? :blink: :blink: :blink:

#5 redalert19882000

    Advanced Member

  • Members
  • PipPipPip
  • 54 posts

Posted 24 December 2006 - 04:26 AM

Sorry for double post!!! I fixed the tutorial... Check again

#6 KiLL3rCLOWN

    Member

  • Members
  • PipPip
  • 16 posts
  • Location:Jacksonville, FL.

Posted 31 December 2006 - 01:13 PM

Is there a way to make it so it will make all the posts on the portal page the same height? I like these edits but it's making each post different sizes. I would prefer to have them all the same height if anyone knows how to do that, I would really appreciate it. Thanks

#7 cinek

    Newbie

  • Members
  • Pip
  • 4 posts

Posted 10 January 2007 - 09:01 AM

View Postredalert19882000, on Dec 24 2006, 11:23 AM, said:

E???? :blink: :blink: :blink:


lol compare it to the tutorial :P

#8 Guest_miguelmayo_*

  • Guests

Posted 23 January 2007 - 12:27 PM

I used this to good effect, I tried a similar thing in the skin but this is much better. I did it your way....and I added some setting in the admin area to change the teaser length from the portal settings page. I need that since I use a lot of images in the portal and they always cut off too short and display the html.


Open up your acp and under admin tab>SQL Management> SQL toolbox - scroll down to run a manual query. assuming your using the standard ibf_ prefix for the tables!

INSERT INTO `ibf_up_settings` (`name`, `value`) VALUES ('tease_length', '400');


Edit the file /public_html/forum/sources/action_admin/uportal.php

find the code below near line 309

$this->ipsclass->html .= $this->ipsclass->adskin->add_td_row( array( "<b>Number of Latest News Items to display:</b>" ,
										  $this->ipsclass->adskin->form_input( "num_latest_news", $GLOBALS['setting']['num_latest_news']  )
								 )	  );


Add Below that
$this->ipsclass->html .= $this->ipsclass->adskin->add_td_row( array( "<b>How many charactors to show?</b>" ,
										  $this->ipsclass->adskin->form_input( "tease_length", $GLOBALS['setting']['tease_length']  )
								 )	  );


Open the file /public_html/forum/sources/action_public/uportal.php - same name as the admin file, diff folder!

Now do the same edit redalert did in NEWS not Latest news

find
while($fetch = $this->ipsclass->DB->fetch_row($query))
			{


Add below
$fetch[post] = substr($fetch[post], 0, $GLOBALS['setting']['tease_length']).$this->ipsclass->lang['more'];



I also wanted to dress up the title of each block a bit so I added a line above that which puts an intro in front of the title "Featured forum post ::"
$fetch[title] = ($this->ipsclass->lang['news_main'].$fetch[title]);


Open up file /public_html/forum/cache/lang_cache/en/lang_uportal.php
stick in a new line in there somewhere with the others
'news_main'  => "Featured Forum Post :: ",
'more'  => ".....[more] ",


#9 redalert19882000

    Advanced Member

  • Members
  • PipPipPip
  • 54 posts

Posted 25 January 2007 - 07:47 AM

Nice Man!!! Nice Tutorial!

#10 moto823

    Newbie

  • Members
  • Pip
  • 3 posts

Posted 27 January 2007 - 11:53 AM

Does anyone know how to make it so you have the scrollers next to it instead of this?

I like the mod, however, having the scrolling bars were fantastic and worked out awsome!

Can someone do it?

#11 kostassakel

    Newbie

  • Members
  • Pip
  • 8 posts
  • Gender:Male
  • Location:Athens

Posted 30 January 2007 - 03:46 AM

That's great! Thanks guys.. :)

#12 TimTam

    Newbie

  • Members
  • Pip
  • 6 posts

Posted 07 May 2007 - 03:32 AM

hi guyz, how 'bout i want 2 link the the post's link to its tile and "[more]" instead of "View Commnent" only. How can i do it?

#13 highlander

    Advanced Member

  • Members
  • PipPipPip
  • 33 posts

Posted 07 May 2007 - 11:01 PM

Hello Tim.. what forum you got?

#14 TimTam

    Newbie

  • Members
  • Pip
  • 6 posts

Posted 10 May 2007 - 01:23 AM

@ highlander: i've got the ipb 2.2.1, thanks :D

#15 highlander

    Advanced Member

  • Members
  • PipPipPip
  • 33 posts

Posted 12 May 2007 - 08:29 PM

address???

upgrade please

#16 TimTam

    Newbie

  • Members
  • Pip
  • 6 posts

Posted 15 May 2007 - 08:40 PM

http://forum.buidoionline.net

thanks for that

#17 cricket

    Administrator

  • Root Admin[Root Admin]
  • PipPipPip
  • 301 posts

Posted 02 August 2008 - 03:38 PM

Remember, that if you have HTML or BBCode in your posts, then this WILL break your portal almost garuanteed. Say you have <a href='Test'</a> and your 400th character is the "s" in that previous example, then you'll have a missing closed </a> tag, and that's not good.
Posted Image





1 user(s) are reading this topic

0 members, 1 guests, 0 anonymous users