vb.org Archive

vb.org Archive (https://vborg.vbsupport.ru/index.php)
-   Modification Graveyard (https://vborg.vbsupport.ru/forumdisplay.php?f=224)
-   -   Major Additions - vbNews by Mary (https://vborg.vbsupport.ru/showthread.php?t=144166)

MaryTheG(r)eek 04-07-2007 04:25 AM

Quote:

Originally Posted by Wulfnoth (Post 1221339)
A very cool hack.
But I have a little problem. If I choose to save the css-stylesheet in vbulletin_css the vbnews.php dosn't works correct. Is their any soluccion for this problem?

Sorry for my bad english, but I had slept in school for the last 10 years... ;)

I know how to solve this problem but I'm still trying to find where the variable $style[css] is hidden:cool: This variable when css is in filesystem adds this line of code at header:
Code:

<link rel="stylesheet" type="text/css" href="clientscript/vbulletin_css/style-2097d366-00001.css" id="vbulletin_css" />
This link must be change to:
Code:

<link rel="stylesheet" type="text/css" href="http//www,domain.com/forums/clientscript/vbulletin_css/style-2097d366-00001.css" id="vbulletin_css" />
When I'll find it, I'll be back:D Please note that this applies only to those installations where vbnews.php is not on your forum directory.

X Quiz 04-07-2007 04:53 AM

Coooool, I like it!!

I will try it today!!

*install*

calorie 04-07-2007 05:03 AM

Quote:

Originally Posted by MicroHellas (Post 1221635)
... but I'm still trying to find where the variable $style[css] is hidden...

The $style variable is set near the style_fetch hook so you could use the next hook:
Code:

$style['css'] = str_replace('clientscript', $vbulletin->options['bburl'] . '/clientscript', $style['css']);

Rican 04-07-2007 05:04 AM

nice hack... however, I am getting this error when trying to upload an image with an article:

Warning: move_uploaded_file(./vbnews/tmp/phpZNIVHh.jpg): failed to open stream: No such file or directory in /vbnews.php on line 444

Warning: move_uploaded_file(): Unable to move '/tmp/phpZNIVHh' to './vbnews/tmp/phpZNIVHh.jpg' in /vbnews.php on line 444

help?

MaryTheG(r)eek 04-07-2007 05:15 AM

Quote:

Originally Posted by Rican (Post 1221653)
nice hack... however, I am getting this error when trying to upload an image with an article:

Warning: move_uploaded_file(./vbnews/tmp/phpZNIVHh.jpg): failed to open stream: No such file or directory in /vbnews.php on line 444

Warning: move_uploaded_file(): Unable to move '/tmp/phpZNIVHh' to './vbnews/tmp/phpZNIVHh.jpg' in /vbnews.php on line 444

help?

Have you CMOD 777 dierectories /photos, /tmp (under vbnews) and /thumbs under /vbnews/photos ?

Rican 04-07-2007 05:32 AM

Yeah, even double checked to make sure I did...

MaryTheG(r)eek 04-07-2007 05:41 AM

Quote:

Originally Posted by Rican (Post 1221669)
Yeah, even double checked to make sure I did...

That's 100% error message of file permissions to write. Please note that even if I post it here just yesterday the mod is already in 1.2.0 version which means that has been tested a lot and all similar errors were depending on file permissions.
Have you follow the directory structure right? eg:
vbnews.php
and directory vbnews must be on the same level. Also variables for paths and URL in vbnews.php have been setup correctly?

Rican 04-07-2007 05:46 AM

alright mate, got it sorted... i had moved the vbnews.php file and forgot to update the urls in the file... :)

now, i just gotta get $40 so i can embed some videos haha...

MaryTheG(r)eek 04-07-2007 06:08 AM

Quote:

Originally Posted by calorie (Post 1221650)
The $style variable is set near the style_fetch hook so you could use the next hook:
Code:

$style['css'] = str_replace('clientscript', $vbulletin->options['bburl'] . '/clientscript', $style['css']);

Thank you Calorie for pointing me to the right way. I always appreciate your help. Actually you're the only one that replies to me.

Maria

MaryTheG(r)eek 04-07-2007 06:13 AM

Quote:

Originally Posted by Wulfnoth (Post 1221339)
A very cool hack.
But I have a little problem. If I choose to save the css-stylesheet in vbulletin_css the vbnews.php dosn't works correct. Is their any soluccion for this problem?

Sorry for my bad english, but I had slept in school for the last 10 years... ;)

There are 2 ways to solve this problem:
  • Open product-vbnews.xml and at after line 1532 add:
Code:

<plugin active="1" executionorder="10">
  <title>Fix CSS Path</title>
  <hookname>cache_templates</hookname>
  <phpcode><![CDATA[
        $style['css'] = str_replace('href="clientscript', 'href="' . $vbulletin->options['bburl'] . '/clientscript', $style['css']);
      ]]></phpcode>
</plugin>

....or....
  • Download again zip file and re-import product-vbnews.xml . Please dont forget to check "Overwrite".
Zip File Updated

Many thanks to Calorie for pointing me to the right way.


All times are GMT. The time now is 02:50 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.01391 seconds
  • Memory Usage 1,745KB
  • 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
  • (6)bbcode_quote_printable
  • (1)footer
  • (1)gobutton
  • (1)header
  • (1)headinclude
  • (6)option
  • (1)pagenav
  • (1)pagenav_curpage
  • (3)pagenav_pagelink
  • (1)pagenav_pagelinkrel
  • (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