vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   vBulletin 4.x Add-ons (https://vborg.vbsupport.ru/forumdisplay.php?f=245)
-   -   vBulletin CMS Widgets - Weather Channel widget that uses members zip code (https://vborg.vbsupport.ru/showthread.php?t=244605)

benstillman 01-05-2011 02:06 PM

Quote:

Originally Posted by Richard Evans (Post 2134375)
How to you add the profile field (Zip Code). I am unfamiliar with where that is.
thanks in advance

admincp

User Profile Fields

Add profile field

http://yourwebsite.com/admincp/profilefield.php?do=add

benstillman 01-05-2011 02:12 PM

Quote:

Originally Posted by aenable (Post 2121041)
FWIW, I had to change this line:
Code:

Add your <A HREF="{vb:raw vboptions.bburl}">$/profile.php?do=editprofile">Zip Code</A> to show weather forcast.
to this:
Code:

Add your <A HREF="{vb:raw vboptions.bburl}/profile.php?do=editprofile">Zip Code</A> to show weather forecast.
to fix the link in the widget when there is no zip code showing.

(VB4.0.7)

Thanks!

Fixed. Thanks!

Quote:

Originally Posted by Octavius. (Post 2132996)
In that code he posted you will see fieldXX and if you look a little further you'll see field8

Replace both fieldXX and field8 with the profile field number that you created for the zip code.

That's the fist part.

Second part, do what aenable did in his post.

3rd part, Take that whole code and put it inside the new vbcms_widget_weather template

Then create your static html widget and copy that same code into Configure.

If you have more than one forum skin, you'll have to create a vbcms_widget_weather for each template.

For instance, I have 11 skins so I had to make 11 new templates but configure the widget only one time.

Added your instructions to the original post.

ThisIrksMe 01-07-2011 12:23 AM

Does this not work for vB4.1PL2?

kenmoresp 01-13-2011 01:55 AM

Question,
Will the work for 3.8.x ???

Boofo 01-13-2011 05:14 AM

You might want to add a TXT file to the first post with the instructions in it. That way they will have it in case they need to re-install it, for whatever reason, sometime in the future.

expediteinsight 01-30-2011 04:11 AM

<span style="text-decoration: line-through">Sorry, I'm a little confused on how to implement this.

I have added the zip code field, and modified the code with the correct field number. I also created a new style named vbcms_widget_weather and created the new widget.

I am stuck on two things: 1) Insert the following into the new template, and 2)Configure the widget to use the "vbcms_widget_weather" template.

Where do you insert the code into the new template? I am using VB 4, and it looks like the "main css" area is no longer supported. Do I need to upload an XML file?

And then after that is done, how do I link the style with the widget?</span>

Edit:
I figured it out. I was going to delete this, but in case anyone has the same problem, I will explain what I did.

I was confusing "new style" with "new template" for an existing style. If you go to Style Manager > Drop-down menu for your current style > Add new template, you will be able to add vbcms_widget_weather and paste the code into the large text box.

Then, when you create the new widget, click Configure. Once again paste the code into this text box (I'm not sure why it needs to be in both places, but I just started using vbulletin today so I am very new). Then below the Static html box, there is a "template name" field. Paste vbcms_widget_weather into this field.

benstillman 02-08-2011 02:51 PM

Quote:

Originally Posted by ThisIrksMe (Post 2145210)
Does this not work for vB4.1PL2?

Works on my 4.1.1 dev site.

rbc1225 04-19-2011 11:50 PM

Quote:

Originally Posted by expediteinsight (Post 2156314)
[S]Sorry, I'm a little confused on how to implement this.

I have added the zip code field, and modified the code with the correct field number. I also created a new style named vbcms_widget_weather and created the new widget.

I am stuck on two things: 1) Insert the following into the new template, and 2)Configure the widget to use the "vbcms_widget_weather" template.

Where do you insert the code into the new template? I am using VB 4, and it looks like the "main css" area is no longer supported. Do I need to upload an XML file?

And then after that is done, how do I link the style with the widget?[/S]

Edit:
I figured it out. I was going to delete this, but in case anyone has the same problem, I will explain what I did.

I was confusing "new style" with "new template" for an existing style. If you go to Style Manager > Drop-down menu for your current style > Add new template, you will be able to add vbcms_widget_weather and paste the code into the large text box.

Then, when you create the new widget, click Configure. Once again paste the code into this text box (I'm not sure why it needs to be in both places, but I just started using vbulletin today so I am very new). Then below the Static html box, there is a "template name" field. Paste vbcms_widget_weather into this field.

That totally cleared any problem I was having. Thanks a lot.

EdQ 07-09-2011 03:48 PM

Quote:

Originally Posted by expediteinsight (Post 2156314)

Edit:
I figured it out. I was going to delete this, but in case anyone has the same problem, I will explain what I did.

I was confusing "new style" with "new template" for an existing style. If you go to Style Manager > Drop-down menu for your current style > Add new template, you will be able to add vbcms_widget_weather and paste the code into the large text box.

Then, when you create the new widget, click Configure. Once again paste the code into this text box (I'm not sure why it needs to be in both places, but I just started using vbulletin today so I am very new). Then below the Static html box, there is a "template name" field. Paste vbcms_widget_weather into this field.

You don't need it in both places.

I copied this into the widget which I think just calls out the template.

PHP Code:

<div class="cms_widget">
    <
div class="block">
        <
div class="cms_widget_header">
        <
h3>{vb:raw widget_title}</h3>
        </
div>
        <
div class="cms_widget_content"


The I created the template as written, but I did it in my parent style so I didn't have to create it in all my styles.

It works. Thanks.

jmp51483 09-04-2011 02:02 AM

works well here thanks!


All times are GMT. The time now is 08: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.02063 seconds
  • Memory Usage 1,749KB
  • 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
  • (1)bbcode_php_printable
  • (6)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (3)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