vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vBulletin 2.x Full Releases (https://vborg.vbsupport.ru/forumdisplay.php?f=4)
-   -   Admins creates threads which are actually links (https://vborg.vbsupport.ru/showthread.php?t=36891)

Jawelin 04-26-2002 12:11 PM

FireFly, I installed this hack correctly but when i create a new thread and fill the url field, actually doesn't happen anything....
:(

FoA, the URL text field at first time contains the string \"\" ... is it normal ?

Actually, I verified by phpMyAdmin, the thread row has the 'link' field empty.
I double-checked in particular the hack applied to newthread.php but everything seems well done... :(

Thank you for any help.

Jawelin 04-26-2002 12:38 PM

Quote:

Originally posted by Jawelin
FoA, the URL text field at first time contains the string \"\" ... is it normal ?
Thanks. Solved myself.
As you can see, I used the txt version output of vbhacker procedure... with the known problem of '"\' ... I made the correction to the new template and everything went fine. Probably that double slash/quote created some kind of problem when writing the url into db...
Now it's ok.

Thanks again.

Russ 05-29-2002 10:49 AM

Would be good to know how you did that.. because I'm having the same problem.

details :)

Russ 05-29-2002 11:29 AM

Just figured it out before the PM came from you :)

So here tis.

You need to change your newthread_linkoption to this:
PHP Code:

Link this thread to: <input type="text" name="link" value="$linkclass="bginput" size="40"><br

Enjoy.

Boofo 06-01-2002 01:05 PM

I just installed the vbhacker version of this and I must have missed something. Where is the box to put the URL in? And where is the delete button for the link? Can someone please tell me what I missed or am missing?

Allstar DC 06-02-2002 09:06 PM

Quote:

Originally posted by Boofo
I just installed the vbhacker version of this and I must have missed something. Where is the box to put the URL in? And where is the delete button for the link? Can someone please tell me what I missed or am missing?

Same problem here

Allstar DC 06-02-2002 09:46 PM

ok, fixed!

i found a lil bug, it doesn't update the "new thread" template
the hack searches for this line but thats wrong!!
PHP Code:

         <input type=\"checkbox\" name=\"parseurl\" value=\"yes\" $parseurlchecked> <b>Automatically parse URLs:</b> automatically adds [url] and [/url] around internet addresses. 


to make this hack work do the following, search for this line in your "new thread" template:

PHP Code:

        <input type="checkbox" name="parseurl" value="yes" $parseurlchecked> <b>Automatically parse URLs:</bautomatically adds url ] and [ /url around internet addresses

and replace it with this:
PHP Code:

         $linkoption
        
<input type="checkbox" name="parseurl" value="yes" $parseurlchecked> <b>Automatically parse URLs:</bautomatically adds url ] and [ /url around internet addresses

remove the spaces between [ url ] and [ /url ]

next open the newly created "newthread_linkoption" template

and replace the coding with this:
PHP Code:

Link this thread to: <input type="text" name="link" value="$linkclass="bginput" size="40"><br

ok, now it will work

kippesp 06-04-2002 03:10 AM

This modification to postings.php will prevent sticking/unsticking
a thread-which-is-a-link from going to the link URL when
the stick/unstick action is performed.

Find:
Code:

  eval("standardredirect(\"".gettemplate("redirect_sticky")."\",\"showthread.php?s=$session[sessionhash]&threadid=$threadid\");");
and replace with:
Code:

  if (empty($threadinfo['link'])) {
    eval("standardredirect(\"".gettemplate("redirect_sticky")."\",\"showthread.php?s=$session[sessionhash]&threadid=$threadid\");");
  } else {
    eval("standardredirect(\"".gettemplate("redirect_sticky")."\",\"forumdisplay.php?s=$session[sessionhash]&forumid=$threadinfo[forumid]\");");
  }

Regarding sticking/unsticking...I was seeing an error message
with this and found it could be eliminated by using session[dbsession]
in the URL for when the thread is stuck/unstuck. My forum didn't
like me browsing with cookies I guess.

Boofo 06-04-2002 09:15 AM

You lost me here on this one and on the dbsession part. :)

Quote:

Originally posted by kippesp
This modification to postings.php will prevent sticking/unsticking
a thread-which-is-a-link from going to the link URL when
the stick/unstick action is performed.

Find:
Code:

  eval("standardredirect(\"".gettemplate("redirect_sticky")."\",\"showthread.php?s=$session[sessionhash]&threadid=$threadid\");");
and replace with:
Code:

  if (empty($threadinfo['link'])) {
    eval("standardredirect(\"".gettemplate("redirect_sticky")."\",\"showthread.php?s=$session[sessionhash]&threadid=$threadid\");");
  } else {
    eval("standardredirect(\"".gettemplate("redirect_sticky")."\",\"forumdisplay.php?s=$session[sessionhash]&forumid=$threadinfo[forumid]\");");
  }

Regarding sticking/unsticking...I was seeing an error message
with this and found it could be eliminated by using session[dbsession]
in the URL for when the thread is stuck/unstuck. My forum didn't
like me browsing with cookies I guess.


kippesp 06-04-2002 04:58 PM

Quote:

Originally posted by Boofo
You lost me here on this one and on the dbsession part. :)


I think only I and Parker Clack didn't like certain things regarding managing
these types of threads. I had an earlier modification to prevent the
following: after initially creating the link thread, vB goes to the thread view
but is redirected to the link. My preference is to go to the forum view.
Firefly for whatever reason didn't use this in his latest update.

My last post fixed a similar situation I didn't like. This with regard to
sticking/unsticking the link thread. Same scenerio: if I stick an unstuck
thread, vB goes to the thread view but is redirected to the link. My code
modifications change that to the way I prefer.

As far as that last bit, that was too vague--sorry. I don't know if I put the
hack in incorrectly or I have a browser problem. But if I am browsing with
cookies (where only 's=' without the sessionidi shows up in my address bar),
trying to use the stick/unstick link takes me to an error window: Your
session appears to be invalid. Click here to create a new session.
If I
browse without cookies, no error message. But I can eliminate the error all
the time with the following code change in forumdisplay.php (taken from
Firefly's first post).
Code:

        $thread['deletelink'] = '';
        if (empty($thread['link'])) {
                $thread['link'] = "showthread.php?s=$session[sessionhash]&threadid=$thread[threadid]";
        } else {
                $thread['link'] = $thread['link'];
                if ($bbuserinfo['usergroupid'] == 6) {
                        $thread['deletelink'] = "(<a href=\"postings.php?s=$session[sessionhash]&action=deletethread&threadid=$thread[threadid]\">delete</a> | <a href=\"postings.php?s=$session[dbsessionhash]&action=stick&threadid=$thread[threadid]\">stick / unstick</a>)";
                }
        }

Only a single word is changed: sessionhash-->dbsessoinhash.

I was a bit surprised no one has mentioned similar situations.
But this would corrected it if they did.


All times are GMT. The time now is 01:35 PM.

Powered by vBulletin® Version 3.8.12 by vBS
Copyright ©2000 - 2025, vBulletin Solutions Inc.

X vBulletin 3.8.12 by vBS Debug Information
  • Page Generation 0.01155 seconds
  • Memory Usage 1,769KB
  • Queries Executed 10 (?)
More Information
Template Usage:
  • (1)ad_footer_end
  • (1)ad_footer_start
  • (1)ad_header_end
  • (1)ad_header_logo
  • (1)ad_navbar_below
  • (5)bbcode_code_printable
  • (5)bbcode_php_printable
  • (4)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (4)pagenav_pagelink
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (10)printthreadbit
  • (1)spacer_close
  • (1)spacer_open 

Phrase Groups Available:
  • global
  • postbit
  • showthread
Included Files:
  • ./printthread.php
  • ./global.php
  • ./includes/init.php
  • ./includes/class_core.php
  • ./includes/config.php
  • ./includes/functions.php
  • ./includes/class_hook.php
  • ./includes/modsystem_functions.php
  • ./includes/class_bbcode_alt.php
  • ./includes/class_bbcode.php
  • ./includes/functions_bigthree.php 

Hooks Called:
  • init_startup
  • init_startup_session_setup_start
  • init_startup_session_setup_complete
  • cache_permissions
  • fetch_threadinfo_query
  • fetch_threadinfo
  • fetch_foruminfo
  • style_fetch
  • cache_templates
  • global_start
  • parse_templates
  • global_setup_complete
  • printthread_start
  • pagenav_page
  • pagenav_complete
  • bbcode_fetch_tags
  • bbcode_create
  • bbcode_parse_start
  • bbcode_parse_complete_precache
  • bbcode_parse_complete
  • printthread_post
  • printthread_complete