vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vBulletin 3.5 Add-ons (https://vborg.vbsupport.ru/forumdisplay.php?f=113)
-   -   WebTemplates 3.5.x: VB Integrated CMS (Content Management System) (https://vborg.vbsupport.ru/showthread.php?t=103076)

Guest210212002 01-18-2006 02:15 AM

Please do post some clarification - I use WT a TON, and I have no idea what you're asking. :D

Bluestrike2 01-18-2006 04:45 AM

Quote:

Originally Posted by Chris-777
Please do post some clarification - I use WT a TON, and I have no idea what you're asking. :D

Need. More. Caffeine. :D

You have the two column template. There are two tables with the stock one. As far as I can tell the only editable one (by the users who are able to edit them but don't have access to the admin CP) is the one on the right (herein referred to as the main table).

On the left column (the smaller column) you have the secondary tables.

My question - is it possible to add more "secondary tables" which are editable by the people who are allowed to with the HTML template editor (the basic one) and multiple boxes (one for each "table").

Does that make sense? What does is the fact that I need sleep :D.

Logician 01-18-2006 07:49 AM

Quote:

Originally Posted by Bluestrike2
You have the two column template. There are two tables with the stock one. As far as I can tell the only editable one (by the users who are able to edit them but don't have access to the admin CP) is the one on the right (herein referred to as the main table).

On the left column (the smaller column) you have the secondary tables.

My question - is it possible to add more "secondary tables" which are editable by the people who are allowed to with the HTML template editor (the basic one) and multiple boxes (one for each "table").

I don't think so.

The crucial point is that you can make any part of a theme editable. So if you want to a section in the left column be editable, then you can edit your theme and put $includedtemplate variable to that section instead of into the right column.

However this variable is unique per theme so you have to put it into one section only. In other words you can NOT make it so that one section in the right and another section in the left is editable at the same time in editor interface.

Hope this sheds a light

Guest210212002 01-18-2006 03:44 PM

I just wanted to chime in and say thanks for this addon Logician, my site wouldn't be the same without it. :)

Bluestrike2 01-19-2006 09:25 AM

Quote:

Originally Posted by Logician
I don't think so.

The crucial point is that you can make any part of a theme editable. So if you want to a section in the left column be editable, then you can edit your theme and put $includedtemplate variable to that section instead of into the right column.

However this variable is unique per theme so you have to put it into one section only. In other words you can NOT make it so that one section in the right and another section in the left is editable at the same time in editor interface.

Hope this sheds a light

Ok - thanks for your help!

Kihon Kata 01-19-2006 12:55 PM

I have a question. Is there a way to make the headers/footers parse php? I use your system here, it's the bomb, but I would like my templates to remain HTML only(user editing purposes). The problem is tht mysite is run on PHP and when I construct sections user this system OUTSIDE my forums, I have to make it parse the template in PHP(plus include some php functions in the template) to make it work. I could easily include that in the custom header, but the header doesn't work with php.

Logician, let me know what you think.

Logician 01-19-2006 01:44 PM

Quote:

Originally Posted by TonysDesigns
I have a question. Is there a way to make the headers/footers parse php? I use your system here, it's the bomb, but I would like my templates to remain HTML only(user editing purposes). The problem is tht mysite is run on PHP and when I construct sections user this system OUTSIDE my forums, I have to make it parse the template in PHP(plus include some php functions in the template) to make it work. I could easily include that in the custom header, but the header doesn't work with php.

Maybe you can run them in the PHPinclude section of the webtemplate? Another idea would be running your code in vbulletin's PHPinclude section, make them ready as variables and use these variables in your custom webtemplate headers.

rasp187 01-19-2006 02:00 PM

How can I change the name of this in the AdminCP to just "WebTemplates" as well as putting it below the vBulletin Options link?

msimonds 01-19-2006 03:00 PM

Logician

My current site uses a cms that is custom:

it is still using vb 3.0.7 (patched) and the CMS is totally custom and uses a the template system within vb

http://www.sportsrant.com is actually a vb template called vb_news

could this template be used in your system, just wanted your input

this is a rather impressive system, nice job sir

regards
Mike
Sportsrant.com

Logician 01-19-2006 05:28 PM

Quote:

Originally Posted by msimonds
Logician

My current site uses a cms that is custom:

it is still using vb 3.0.7 (patched) and the CMS is totally custom and uses a the template system within vb

http://www.sportsrant.com is actually a vb template called vb_news

could this template be used in your system, just wanted your input

this is a rather impressive system, nice job sir

regards
Mike
Sportsrant.com

I'd say it would work if you run it inside forum directory. Apparently you are running outside vb directory but webtemplates is not designed to do so. Probably you can still make it display when you put it in a webtemplate but its URL will be http://www.sportsrant.com/forums/view_YOURPAGE.htm

Kihon Kata 01-19-2006 07:11 PM

Would this increase server load? or DB queries?

Quote:

Originally Posted by Logician
Another idea would be running your code in vbulletin's PHPinclude section, make them ready as variables and use these variables in your custom webtemplate headers.


Logician 01-19-2006 07:43 PM

Quote:

Originally Posted by TonysDesigns
Would this increase server load? or DB queries?

can't say anything without seeing your code but if it is a simple code that does not connect to DB, I'd say no

digitalSite 01-19-2006 11:37 PM

Edit: How do I display "Current members online" instead of "Current members viewing this webtemplate"? In other words, I would like to display the member usernames who are currently logged in, just like at the bottom of FORUMHOME. Thank you!

Thank you for this hack!

Guest210212002 01-20-2006 02:41 AM

Quote:

Originally Posted by rasp187
How can I change the name of this in the AdminCP to just "WebTemplates" as well as putting it below the vBulletin Options link?

[high]* Guest210212002 would also like to know[/high]

digitalSite 01-20-2006 03:13 AM

Also, according to the manual, there is a vB template (not a webtemplate) that is named "WebTemplates_MemberLoginCode," but I do not see this one, I only see "WebTemplates_VisitorLogMain" and "WebTemplates_LoginCode" and some others. Does anyone else have this issue, or is it only me?

If it's just me, where can I change the look of the login box once a member has signed in? Or where can I get the Visitor template, if I am indeed missing it?

Thanks!

Logician 01-20-2006 06:48 AM

Quote:

Originally Posted by Chris-777
[high]* Chris-777 would also like to know[/high]

You have to play with this line at /includes/xml/cpnav_webtemplates.xml:

PHP Code:

navgroup text="Logician's WebTemplates" hr="true" displayorder="1" 


Logician 01-20-2006 06:50 AM

Quote:

Originally Posted by digitalSite
Also, according to the manual, there is a vB template (not a webtemplate) that is named "WebTemplates_MemberLoginCode," but I do not see this one, I only see "WebTemplates_VisitorLogMain" and "WebTemplates_LoginCode" and some others. Does anyone else have this issue, or is it only me?

If it's just me, where can I change the look of the login box once a member has signed in? Or where can I get the Visitor template, if I am indeed missing it?

Thanks!

Template named "WebTemplates_LoginCode"

Kihon Kata 01-20-2006 01:18 PM

I upgraded mine from .04 to .05 per instructions and it worked great. Didn't lose any templates.

Here is an example of some of mine:
  1. Example of a Non vB page using this: http://www.makeuptalk.com/forums/vie...alk-newsletter
  2. Example of a vB page using this: http://www.makeuptalk.com/forums/vie...ewinnerscircle
(Logician, add me to your examples!! ;))

Took some tweaking to make it work outside my forums, but the way Logician setup the viewing permissions, it simply rocks!


Quote:

Originally Posted by Logician
Template named "WebTemplates_LoginCode"


Guest210212002 01-20-2006 01:53 PM

Quote:

Originally Posted by Logician
You have to play with this line at /includes/xml/cpnav_webtemplates.xml:

PHP Code:

navgroup text="Logician's WebTemplates" hr="true" displayorder="1" 


Thankya. I got it renamed no prob, just can't get it below the main options.

Code:

<navgroup text="WebTemplates" hr="true" displayorder="3">

digitalSite 01-20-2006 02:01 PM

Quote:

Originally Posted by Logician
Template named "WebTemplates_LoginCode"

Thanks Logician! I always enjoy your hacks! I have a few more questions...

1) I have created a WebQuery that displays the "Last 10 threads" from any forum, but I would like to show only a limited number of characters in a thread title. In other words, I don't want the entire title displaying, instead, I would like to show something like: "This is a sample..." - Any help on this is greatly appreciated!

I have tried SELECT id, LEFT(title, 20), etc. but this didn't work for me.


2) I would like to remove the Powered by in the footer. How much do you charge to remove it?

Thanks!

nitro 01-20-2006 03:01 PM

This seems to be very nice. My asociate runs the other way when I open vb and vbportal cp's. Now he can just ask for a new page and voila he can edit a page as much as he likes.

Found a minor bug or two tho when placing an image into and editor for TEXT. You can wrap it ok with img bb tags and save, but when you go to edit it again its wrapped it has parsed the url and needs the img tags redoing. Is there anyway to have the dont parse urls checkbox to the editors ?

Logician 01-20-2006 04:27 PM

Quote:

Originally Posted by TonysDesigns
(Logician, add me to your examples!! ;))

Added. I liked what you did with the hack. ;)

Quote:

Originally Posted by TonysDesigns
Took some tweaking to make it work outside my forums, but the way Logician setup the viewing permissions, it simply rocks!

Maybe you can share what you did in the thread so that others will use it too? I'm asked this so many times and frankly speaking I dont have free time to deal with this request.

Logician 01-20-2006 04:29 PM

Quote:

Originally Posted by Chris-777
Thankya. I got it renamed no prob, just can't get it below the main options.

Code:

<navgroup text="WebTemplates" hr="true" displayorder="3">

Set displayorder as 0 or 1 and if there are other hack options above WebTemplates, edit their xml files to increase their displayorder to push them down.

Logician 01-20-2006 04:32 PM

Quote:

Originally Posted by digitalSite
Thanks Logician! I always enjoy your hacks! I have a few more questions...

1) I have created a WebQuery that displays the "Last 10 threads" from any forum, but I would like to show only a limited number of characters in a thread title. In other words, I don't want the entire title displaying, instead, I would like to show something like: "This is a sample..." - Any help on this is greatly appreciated!

I have tried SELECT id, LEFT(title, 20), etc. but this didn't work for me.

You can do it with SUBSTRING like .
SELECT id, SUBSTRING(title, 0 20)..

Please see here http://www.webmasterworld.com/forum88/6209.htm for more info

digitalSite 01-20-2006 08:22 PM

Quote:

Originally Posted by Logician
You can do it with SUBSTRING like .
SELECT id, SUBSTRING(title, 0 20)..

Please see here http://www.webmasterworld.com/forum88/6209.htm for more info

Hi, I tried SELECT id, SUBSTRING(title, 0, 20), etc. and several variations I found in Google, but they are not working. It comes up blank. I know you're busy, so has anyone have theire titles of threads displaying on their site with only the first 10 or 20 characters? I would like to know how. Thanks.

Logician 01-20-2006 08:36 PM

Quote:

Originally Posted by digitalSite
Hi, I tried SELECT id, SUBSTRING(title, 0, 20), etc. and several variations I found in Google, but they are not working. It comes up blank. I know you're busy, so has anyone have theire titles of threads displaying on their site with only the first 10 or 20 characters? I would like to know how. Thanks.

ok try this (import in webtemplate import screen).. I did with left()

digitalSite 01-20-2006 11:03 PM

Quote:

Originally Posted by Logician
ok try this (import in webtemplate import screen).. I did with left()

Hi, this works! Now that we have the X character limit to display, there's just one other problem...the only thing is that although it says LIMIT 0,5 only the first post is shown.

How do we get last 10 to show?

Thanks so much...you should have received an email from PayPal ;)

nitro 01-21-2006 05:40 AM

Quote:

Originally Posted by nitro
This seems to be very nice. My asociate runs the other way when I open vb and vbportal cp's. Now he can just ask for a new page and voila he can edit a page as much as he likes.

Found a minor bug or two tho when placing an image into and editor for TEXT. You can wrap it ok with img bb tags and save, but when you go to edit it again its wrapped it has parsed the url and needs the img tags redoing. Is there anyway to have the dont parse urls checkbox to the editors ?

Yep this would be very annoying. Everytime you edit a TEXT type in the front end in either text or wysiwyg mode it drops img bbcode tags and you have to replace them all. And if you have a few images on a page and forget one then you have to edit again and start agian. It also auto parse urls every save and no option to not do so.

When this is fixed I can consider installing. :)

Logician 01-21-2006 07:26 AM

Quote:

Originally Posted by digitalSite
Hi, this works! Now that we have the X character limit to display, there's just one other problem...the only thing is that although it says LIMIT 0,5 only the first post is shown.

You are suppose to get last 5 in that forum. I get 5 in my test forum. Can it be because you have just 1 thread in that forum?

Logician 01-21-2006 07:33 AM

Quote:

Originally Posted by nitro
This seems to be very nice. My asociate runs the other way when I open vb and vbportal cp's. Now he can just ask for a new page and voila he can edit a page as much as he likes.

Found a minor bug or two tho when placing an image into and editor for TEXT. You can wrap it ok with img bb tags and save, but when you go to edit it again its wrapped it has parsed the url and needs the img tags redoing.

I cant confirm this behaviour. When I use a IMG tag in a webtemplate and then go edit in the editor interface, it parses just fine. I tested both with standart editor and WYSIWYG, all works fine for me.

digitalSite 01-21-2006 08:31 AM

Quote:

Originally Posted by Logician
You are suppose to get last 5 in that forum. I get 5 in my test forum. Can it be because you have just 1 thread in that forum?

Ha! This is true! I do only have one post in this forum...I guess my question should be, how do I list threads from ALL forums? Would I have to add every forum here

WHERE t.forumid = '1','2','3', etc.? Thanks!

I tried removing this WHERE t.forumid = (because I want from ALL forums) and replaced it with WHERE t.open = '1' AND t.visible = '1', but then the titles don't get limited and it posts the entire title.

OMG, I'm having a hard time with this...I noticed that when I run your code, it cuts the title to the limit you specify, but when I copy/paste your code into my webtemplate, it diplays the number of posts correctly, but doesn't cut off the title...any ideas why yours works and mine doesn't?

Logician 01-21-2006 08:46 AM

Quote:

Originally Posted by digitalSite
Ha! This is true! I do only have one post in this forum...I guess my question should be, how do I list threads from ALL forums? Would I have to add every forum here

WHERE t.forum = '1','2','3', etc.? Thanks!

I tried removing this WHERE t.forum = (because I want from ALL forums) and replaced it with WHERE t.open = '1' AND t.visible = '1', but then the titles don't get limited and it posts the entire title.

Your WHERE close is right if you want to pull from all forums.

If you want to restrict title, you need to apply the left() to the title section too:

SELECT t.threadid, LEFT(t.title, 10) as title, t.firstpostid, t.lastpost, t.replycount, t.postusername, t.postuserid, t.lastposter, t.dateline, t.views, LEFT(p.pagetext, 10) as pagetext
FROM " . TABLE_PREFIX . "thread t
LEFT JOIN " . TABLE_PREFIX . "post p ON p.postid = t.firstpostid
WHERE t.open = '1'
AND t.visible = '1'
ORDER BY t.dateline DESC
LIMIT 0 , 5

digitalSite 01-21-2006 09:09 AM

Quote:

Originally Posted by Logician
Your WHERE close is right if you want to pull from all forums.

If you want to restrict title, you need to apply the left() to the title section too:

SELECT t.threadid, LEFT(t.title, 10) as title, t.firstpostid, t.lastpost, t.replycount, t.postusername, t.postuserid, t.lastposter, t.dateline, t.views, LEFT(p.pagetext, 10) as pagetext
FROM " . TABLE_PREFIX . "thread t
LEFT JOIN " . TABLE_PREFIX . "post p ON p.postid = t.firstpostid
WHERE t.open = '1'
AND t.visible = '1'
ORDER BY t.dateline DESC
LIMIT 0 , 5

YEY! This works PERFECTLY! Thank you very much Logician, you're the best!!! (Doing the running man and dancing around the house now...)

For a look at my site, here is what it looks like now (my site is still under construction): http://www.naturalbeautycafe.net/

THANKS!

Logician 01-21-2006 09:16 AM

Quote:

Originally Posted by digitalSite
YEY! This works PERFECTLY! Thank you very much Logician, you're the best!!! (Doing the running man and dancing around the house now...)

For a look at my site, here is what it looks like now (my site is still under construction): http://www.naturalbeautycafe.net/

THANKS!

Glad it worked. Added your site to the demo webtemplates in the first post. I must also tell it to my wife who might be interested being a member ;)

digitalSite 01-21-2006 09:31 AM

Quote:

Originally Posted by Logician
Glad it worked. Added your site to the demo webtemplates in the first post. I must also tell it to my wife who might be interested being a member ;)

Great! No problem! I couldn't find a place online for those interested in all natural products, so I decided to create a community online :) :banana:

htscpl 01-22-2006 03:43 PM

Thanks I've been looking for this. Just upgraded from vb 3.0.11. Lost the webtemplets. ** installs **
H :D

Logician 01-22-2006 06:50 PM

Quote:

Originally Posted by htscpl
Thanks I've been looking for this. Just upgraded from vb 3.0.11. Lost the webtemplets. ** installs **
H :D

Export script should export your old webtemplates for you? You can run it even now if you didnt manually deleted old wt tables.

nitro 01-22-2006 09:05 PM

Its most strange, its only swapping IMG bb tags for URL= tags on my test install. I cannot replicate it live either. I decided to go for it anyway as this by all accounts is a long standing mod, so if its not happening to anyone else it must be some wierd setting somewhere making it happen. :)

I thought perhaps it was a style issue as I havent updated all the styles on my dev box but I've pretty much ruled that out aswell, it does do it in vb's default style which is untouched.

One comment the page title seems to not be editable in the front end only in CP. Might be nice to have some inline stuff on this mod for bits like that.

ammarcom004 01-22-2006 09:15 PM

thanks for this hack

DaFire 01-23-2006 03:13 PM

Hmm.. I'd like to allow certain usergroups to edit pages, which already works great with a few flaws. On my board with about 500 users I have only one admin beside me.. there are several sections with a own leader group but no access to control panel.

1. the editors should be able to toggle the draft flag and should be able to see the page in draft

2. the editors should be able to change the view permission.

Ideally I only create the page, set the allowed webquerys and let the editors do the rest. Even better if I could allow them to create pages themself, but without any possibility to add php code or include files or stuff like that :)


All times are GMT. The time now is 05:00 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.02071 seconds
  • Memory Usage 1,872KB
  • 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
  • (2)bbcode_code_printable
  • (2)bbcode_php_printable
  • (29)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (4)pagenav_pagelink
  • (1)pagenav_pagelinkrel
  • (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