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)

amykhar 04-11-2002 03:11 PM

Chen,
Could a template be created that consists of two frames. The top frame would be a frame for a link back to our board. The bottom frame would be the external page that we linked to. Then, instead of calling the refresh to the new page, your hack would refresh to a script that took the link as a parameter, and then displayed the framed page template?

Sorry if that is confusing.
Amy

TECK 04-11-2002 03:55 PM

this is a great idea. specially for a VB powered frontpage. you could use an invisible forum and grab the list of threads with a query.
thanks firefly for this cool hack. :)

-=dm=- 04-11-2002 04:02 PM

FireFly you da king!!

thanx :)

amykhar 04-11-2002 06:30 PM

Never mind, Chen. I got it. :D

Amy

Smoothie 04-12-2002 02:47 AM

Great hack this is. I'm using it together with c-prOmpt's excellent hack
Thanks again FireFly.

Parker Clack 04-12-2002 09:24 PM

Chen:

I added the ability to Edit the Title of the link too using

$thread['deletelink'] = "<br>( <a href=\"postings.php?s=$session[sessionhash]&action=deletethread&threadid=$thread[threadid]\"> Delete</a> | <a href=\"postings.php?s=$session[sessionhash]&action=stick&threadid=$thread[threadid]\">Stick | Unstick</a> | <a href=\"postings.php?s=$session[sessionhash]&action=editthread&threadid=$thread[threadid]\"> Edit Title</a> )";

Is there anyway to write this so that when you do post a new thread and use the title to go to a different url where it goes back to the original thread (when you first post it) instead of going to the new link?

Parker

kippesp 04-13-2002 02:19 AM

Quote:

Originally posted by Parker Clack
Is there anyway to write this so that when you do post a new thread and use the title to go to a different url where it goes back to the original thread (when you first post it) instead of going to the new link?
In file newthread.php, find:
} elseif ($visible) {
and replace with:
} elseif ($visible and $link=='') {

Parker Clack 04-13-2002 03:42 AM

kippesp:

Thanks. I tried that before but I guess I put it in wrong. It is working great now.

Parker

Ghostsuit 04-16-2002 11:18 AM

The ability to make the link a stick would be great. Is that planed?

!!!cyr0n_k0r 04-20-2002 05:41 PM

you have horriable install instructions for n00bs.

a readme laying out the steps would really be nice.

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.

Jeremy W. 06-05-2002 12:29 AM

I've installed it (no problems with the install), but ... well, it hasn't changed anything...

I mean, I go to start a new thread and there isn't any box. Am I dense or just thick? *L*

Allstar DC 06-05-2002 03:43 AM

Jeremy W. :

Check (post #57) in topic, the fix is posted there

Jeremy W. 06-05-2002 10:21 AM

Great, thanx :)

Birdie501 06-12-2002 12:17 AM

Quote:

Originally posted by FireFly

TheCaver: sure. In forumdisplay.php replace:
Code:

    if (empty($thread['link'])) {
        $thread['link'] = "showthread.php?s=$session[sessionhash]&threadid=$thread[threadid]";
    }

with:
Code:

    if (empty($thread['link'])) {
        $thread['link'] = "showthread.php?s=$session[sessionhash]&threadid=$thread[threadid]";
    } else {
        $thread['link'] .= '" target="_blank';
    }

[/B]
if i put this code to forumdisplay.php i have the following and get a parse error???

PHP Code:

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

What's the problem?

Dan Flynn 09-28-2002 02:45 AM

I have this installed but get this error. Any ideas?

Thanks

Parse error: parse error, unexpected $ in /home2/powerwas/public_html/showthread.php on line 604

somerfeld 10-03-2002 01:50 AM

can i see some screen shots or something?

Smoothie 10-03-2002 06:38 AM

Screen shots? It looks like a thread link, but when you click it, it takes you to whatever the link is. There's nothing to see.....

Antorz 10-15-2002 01:38 AM

I'm also missing all the content in newthread_linkoption

it's linked from newthread w/ $linkoption

and I did all the changes suggested in post #57 of this thead...

do I have my permission wrong or something? I'm testing it using the admin account, with nothing showing up..

Thanks for any help

Mono 11-02-2002 04:34 AM

I installed this hack and it gave me a bunch of errors so I tried to work my way backwards in the hack but decided to freshly install the phps.

Anyway now my thread links link back to the main page and I cant think of how to get them to show the thread anymore :/.

I really need help soon because we have some 3000 plus members and people want to use the board. Any help would be appreciated. Im thinking it has to do with the ALTER TABLE thread ADD link varchar(255) NOT NULL part of the hack because when I go to manuel mode it shows up blank.

Mono 11-02-2002 05:09 AM

Fixed the problem.

-_- it was the forumbits template I forgot to revert .... god I feel like a noob.

Sharg 04-24-2003 01:58 AM

Hello,
does this hacks works with vb 2.3 ?

Also, will there be no troubles when updating to 3.0 since this hack alter the database ?

Thanks,
Sharg

vB-Host.com 04-25-2003 06:53 AM

how can I make a forum id rather then a thread id linkable? So I can make a link kinda like vb.com does in the forums for vb.org and .org does for .com

Erwin 04-25-2003 07:21 AM

Quote:

Today at 05:53 PM vB-Host.com said this in Post #72
how can I make a forum id rather then a thread id linkable? So I can make a link kinda like vb.com does in the forums for vb.org and .org does for .com

This is asked every other day here at vB.org it seems. :) Use the search feature in future.

It's easy - when editing a forum, put this in as the Forum Title:

</a><a href="http://www.google.com">Click here to go to Google!</a>

And the forum will redirect to Google.

There is a hack that can do this too. Do a search in Hack Requests for other variations and extensions.

cinq 04-25-2003 11:25 AM

So does this hack work on 2.2.9 ?

vB-Host.com 04-25-2003 05:48 PM

Quote:

Today at 05:25 AM cinq said this in Post #74
So does this hack work on 2.2.9 ?
yes! flawless install of both vbhacker and this hack on first try... no errors! but be sure to see a post in here.. I beleive post #58 about code changes in 2 of the templates.

http://www.vb-host.com/forum/forumdi...?s=&forumid=13 My site uses 2.2.9 and the sticky click here to go to our help desk is a link using this hack

Quote:

There is a hack that can do this too. Do a search in Hack Requests for other variations and extensions.
Thanks Erwin... Didn't think about just putting the URL as the forum name.. as for searching.. I tried a bunch of different keywords but only this hack came back to anything close.

cinq 04-26-2003 02:16 AM

thanks vbhost for the confirmation, will be installing this hack soon. :)

Nice site btw, hope it becomes busy soon :D

vB-Host.com 04-26-2003 02:40 AM

Quote:

[i]Today at 08:16 PM cinq thanks vbhost for the confirmation, will be installing this hack soon. :)

Nice site btw, hope it becomes busy soon :D

Glad I can help :) Thanks, glad you liked my site... It has been getting a lot of intrest.. The site will be fully completed this weekend.. Of course you need to register to see most of the hacks I installed *grin*

Bison 08-22-2003 05:59 PM

I just installed this hack but when I create a thread and enter the link information, it take me into the threa I created. I know I did this right and went through all fo the code several times and still I get nothing but entry into the thread I created...

StrykerContact 08-24-2003 06:23 AM

Uhh I really am a Noob sorry, how the hell do you install this one, there is no instructions. Sorry if I missed somthing or if this is just a noob question. Please help though thanks ^^.

fn9mm 11-09-2005 07:28 PM

Any update on this??

Possible in 351?


All times are GMT. The time now is 02:44 AM.

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.01399 seconds
  • Memory Usage 1,858KB
  • 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
  • (7)bbcode_code_printable
  • (6)bbcode_php_printable
  • (10)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (2)pagenav_pagelink
  • (1)post_thanks_navbar_search
  • (1)printthread
  • (40)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