[Add-on] Display posts anywhere 1.2.0 RC5

Stand-alone scripts designed for a specific function, but not neccessarily part of normal forum browsing.
Forum rules
Image Please feel free to download any Scripts here, support for each Script is located it's own thread.

To post your own Script, please first read the MOD / Script Guidelines

Re: [Add-on] Display posts anywhere 0.3.0

Postby Handyman » 27 Feb 2007, 01:45

This white page business is really driving me up the wall and across the ceiling.
I can't reproduce it on a fresh Beta 5 so there is no way I'm going to able to convince the dev team.
Somebody else has to report it before we all go insane.
Please contact me if you have any news to submit to SCOFF News.
SCOFFing at the candidates while you sleep.
My Mods || My Mod Queue
Image
User avatar
Handyman    
Rear Fleet Admiral
Rear Fleet Admiral
 
Posts: 7456
Joined: 08 May 2006, 04:45
Location: Where no man has gone before!
Favorite Team: Seattle Seahawks
Gender: Male




phpBB Academy at StarTrekGuide
Support STG
Using PayPal Donate

Re: [Add-on] Display posts anywhere 0.3.0

Postby Kjell » 27 Feb 2007, 02:43

Kn the be a conflict in funktions.php?
The file is to big for spoiler...
Attachments
functions.txt
(122.93 KiB) Downloaded 26 times
Kjelle
My work - My farm - Ware I live - phpBB support Sweden
"The globe is round, think global", My rules: Be teased is okay on a funny way ;)
User avatar
Kjell    
Supporter
Supporter
 
Posts: 490
Joined: 14 Feb 2007, 13:09
Location: Nordic of Sweden
Favorite Team: NHL N-ville,Forsberg
Gender: Male
phpBB Knowledge: 8

Re: [Add-on] Display posts anywhere 0.3.0

Postby Aratgel » 28 Feb 2007, 05:25

I have a small question someone know how to remove the automatic reply abreviation in subject when a user post the "Re:" in the begeining for exemple "Re: [Add-on] Display posts anywhere 0.3.0" ==> "[Add-on] Display posts anywhere 0.3.0"
Aratgel    
Translator
Translator
 
Posts: 31
Joined: 14 Jan 2007, 19:43
Location: Montréal Québec
Favorite Team: Canadiens
Gender: Male

Re: [Add-on] Display posts anywhere 0.3.0

Postby Handyman » 28 Feb 2007, 17:28

Spoiler:
FIND
Code: Select all
'POST_SUBJECT'        => $row['post_subject'],


REPLACE WITH
Code: Select all
'POST_SUBJECT'        => str_replace('Re: '''$row['post_subject']),

Only problem with that is if you have a subject that has Re: in the middle of it? it would be taken out as well.
But since that's an extremely rare occasion, I don't think you need to worry about it.
Please contact me if you have any news to submit to SCOFF News.
SCOFFing at the candidates while you sleep.
My Mods || My Mod Queue
Image
User avatar
Handyman    
Rear Fleet Admiral
Rear Fleet Admiral
 
Posts: 7456
Joined: 08 May 2006, 04:45
Location: Where no man has gone before!
Favorite Team: Seattle Seahawks
Gender: Male

Re: [Add-on] Display posts anywhere 0.3.0

Postby Highway of Life » 28 Feb 2007, 23:02

See line ~1056 of posting.php
Code: Select all
$post_data['post_subject'] = ((strpos($post_data['post_subject'], 'Re: ') !== 0) ? 'Re: ' '') . censor_text($post_data['post_subject']);


Change to:
Code: Select all
$post_data['post_subject'] = ((strpos($post_data['post_subject'], 'Re: ') !== 0) ? '' '') . censor_text($post_data['post_subject']);
Watch out! I might do a code wheelie!

User avatar
Highway of Life    
STG Jedi Master
STG Jedi Master
 
Posts: 10458
Joined: 08 May 2006, 05:23
Location: Beware of Programmers carrying screwdrivers
Gender: Male
phpBB Knowledge: 10

Re: [Add-on] Display posts anywhere 0.3.0

Postby Kjell » 01 Mar 2007, 01:22

Index become white when I use Include of functions_display.php (no debugg code).
But display_anyware.php and display_anyware.html functions.
When I remark that row with functions_display.php, so functions debugg with error.........(good but Scratch )
In functions_display.php no changes in it (mod´s)
What can be wrong?
Kjelle
My work - My farm - Ware I live - phpBB support Sweden
"The globe is round, think global", My rules: Be teased is okay on a funny way ;)
User avatar
Kjell    
Supporter
Supporter
 
Posts: 490
Joined: 14 Feb 2007, 13:09
Location: Nordic of Sweden
Favorite Team: NHL N-ville,Forsberg
Gender: Male
phpBB Knowledge: 8

Re: [Add-on] Display posts anywhere 0.3.0

Postby Handyman » 01 Mar 2007, 02:29

@Highway of Life - I'm trying to make this mod without changing any core code until RC or Gold? that way it can always be used and it will be self contained.

@kjelle - argh Rant I hate that bug.
What do you have in your template?

You may only want to put that code in functions.php? then you won't have to include it.
And if you have it in functions.php and functions_display.php, that is why you are seeing a blank page.
Please contact me if you have any news to submit to SCOFF News.
SCOFFing at the candidates while you sleep.
My Mods || My Mod Queue
Image
User avatar
Handyman    
Rear Fleet Admiral
Rear Fleet Admiral
 
Posts: 7456
Joined: 08 May 2006, 04:45
Location: Where no man has gone before!
Favorite Team: Seattle Seahawks
Gender: Male

Re: [Add-on] Display posts anywhere 0.3.0

Postby Kjell » 01 Mar 2007, 03:07

The mods are
Ajax chat 2.0.0 Beta 4
Animate Digits IP Tracking Counter 0.2.0
Avatar on mebberlist
lastrssphpbb3_1_1 (lastrss)
phpbb3-portal.100b
(get_last_posts Scratch )

Running Subsilver, subsilver-mod (may own), subsilver+

In get last posts mod "include($phpbb_root_path . 'includes/functions_display.' . $phpEx);"
Code: Select all
function get_last_posts($limit, $extra_id = false, $type = false)
{
    global $db, $phpbb_root_path, $phpEx, $template;
   global $cache, $user, $auth, $config, $user_cache;

//   include($phpbb_root_path . 'includes/functions_display.' . $phpEx);
        include($phpbb_root_path . 'includes/functions_display.' . $phpEx);
   if ($extra_id)
   {
      switch($type)..................................
Last edited by Kjell on 01 Mar 2007, 03:25, edited 1 time in total.
Kjelle
My work - My farm - Ware I live - phpBB support Sweden
"The globe is round, think global", My rules: Be teased is okay on a funny way ;)
User avatar
Kjell    
Supporter
Supporter
 
Posts: 490
Joined: 14 Feb 2007, 13:09
Location: Nordic of Sweden
Favorite Team: NHL N-ville,Forsberg
Gender: Male
phpBB Knowledge: 8

Re: [Add-on] Display posts anywhere 0.3.0

Postby Handyman » 01 Mar 2007, 03:24

Hmm? I wonder if that is being included already.
Go ahead and comment out both of those? why are there 2 in there?
Let me know how that works.

Edit: Replace those 2 lines with this
Code: Select all

$included_files 
get_included_files();
if (!
in_array('functions_display'$included_files))
{
    include(
$phpbb_root_path 'includes/functions_display.' $phpEx);
}
Please contact me if you have any news to submit to SCOFF News.
SCOFFing at the candidates while you sleep.
My Mods || My Mod Queue
Image
User avatar
Handyman    
Rear Fleet Admiral
Rear Fleet Admiral
 
Posts: 7456
Joined: 08 May 2006, 04:45
Location: Where no man has gone before!
Favorite Team: Seattle Seahawks
Gender: Male

Re: [Add-on] Display posts anywhere 0.3.0

Postby Kjell » 01 Mar 2007, 03:37

Nope Scratch

" Bang Head Bang Head "


Code: Select all
function get_last_posts($limit, $extra_id = false, $type = false)
{
    global $db, $phpbb_root_path, $phpEx, $template;
   global $cache, $user, $auth, $config, $user_cache;

$included_files = get_included_files();
if (!in_array('functions_display', $included_files))
{
    include($phpbb_root_path . 'includes/functions_display.' . $phpEx);
}
   if ($extra_id)
   {
      switch($type)
      {

Does someone more tried?
Kjelle
My work - My farm - Ware I live - phpBB support Sweden
"The globe is round, think global", My rules: Be teased is okay on a funny way ;)
User avatar
Kjell    
Supporter
Supporter
 
Posts: 490
Joined: 14 Feb 2007, 13:09
Location: Nordic of Sweden
Favorite Team: NHL N-ville,Forsberg
Gender: Male
phpBB Knowledge: 8

PreviousNext

Return to Scripts

Who is online

Users browsing this forum: Sosospider and 6 guests