zCommunity 0.8.1 Beta Now available! (supports SMF 2.0 RC1 and 1.1.8)

Started by Charles Hill, June 16, 2008, 03:33:34 PM

Previous topic - Next topic

Smoky "Rider" Blue

#420
Quote from: Charles Hill on September 14, 2008, 10:21:47 PM
@ SmokyBlue...  Undefined index errors mean that a variable is being used that hasn't been set yet.  rss_feed is a txt variable.  Most likely you're just missing this variable in your Blog language file.  can_poll_view is a context variable.  It is a context variable.  It should only be used if viewing the blog control panel... Maybe your BlogSettings.php.  Make sure you can find the following in the blogControlPanel2 function in Blog.php:
'can_poll_view' => 'poll_view',

i found this in the settings charles:



$poll_permissions = array(
'can_poll_view' => 'poll_view',
'can_poll_vote' => 'poll_vote',



so this is right.. ;)

edit:

i have gone back over the settings and checked everythingg i was supposed to, but i still am showing errors in the log:

Quote8: Undefined index: sideWindows
File: /hsphere/local/home/***/forum/Themes/default/Blog.template.php (main sub template - eval?)
Line: 614

and

8: Undefined index: rss_feed
File: /hsphere/local/home/***forum/Themes/default/Blog.template.php (main sub template - eval?)
Line: 782

i have enabled everything i can.. still nothing gives..
**Take the time to remember friendships and family.. Sometimes it's all we have, and missed very much**

Charles Hill

#421
The sideWindows error...... That is actually a mistake I made with the default blog template.... I forgot to change something in the template_sideWindow($array) function....

I make changes on my template files and then I make the changes to the default template version.... Anyways.. find the following in Blog.template.php:
global $context;
// it's done this way for ordering purposes...
for ($i = 1; $i <= count($context['blog']['sideWindows']); $i++)
{


replace with:
global $context, $settings, $scripturl, $txt;

if (empty($context['viewing_blog_index']))
$sideWindows = $context['blog']['sideWindows'];
else
$sideWindows = $context['blog']['blogIndexSideWindows'];

// it's done this way for ordering purposes...
for ($i = 1; $i <= count($sideWindows); $i++)
{


This is probably why your side windows weren't working right.  Also... the rss_feed is a txt variable which *should* be in your Blog language file.



edit---
About that mysql error at line 724... did you do the fixes that I suggested?  It has to do with $context['visible_blogs'] being empty....

Amun

#422
Fatal error: Cannot redeclare blogcopyright() (previously declared in /home/content/p/e/a/peacefrog/html/Sources/Subs.php:4069) in /home/content/p/e/a/peacefrog/html/Sources/Subs.php on line 4072

I can't access any pages of my site now after I installed the mod I keep getting that error XD

Fixed it for what ever reason it was there was duplicates of code xD
:D :D :D

Smoky "Rider" Blue

Charles, the msql is gone.. error no more.. i re did the db and then applied your mod and the rest of them.. one at a time,, to double check, as this is a paid job for me..

only errors now are the rss and side windows.. i will make the corrections now and thank you for helping me out with this..

if i can not find the rss txt variable, could you post it up for me please?
**Take the time to remember friendships and family.. Sometimes it's all we have, and missed very much**

Charles Hill

@SmokyBlue... Oh I just went to find it in my language files and apparently I forgot to put it in the Blog language file.

It's $txt['rss_feed'] = 'RSS Feed';

Smoky "Rider" Blue

thank you very much Charles.. i am sure this is going to be a great mod..

keep up the good work you are doing with it.. you are a life saver ;)
**Take the time to remember friendships and family.. Sometimes it's all we have, and missed very much**

Smoky "Rider" Blue

much better!!!!

thank you tons Charles.. the edits are great.. no errors from the mod at all now.. i love it when its like that!! yes!! lol 22 mods with zero errors..

thanks again Charles..  ;)
**Take the time to remember friendships and family.. Sometimes it's all we have, and missed very much**

Charles Hill


robbie93


Charles Hill

Could you attach your Blog.php please?

runebergen

Quote from: SmokyBlue on September 15, 2008, 11:40:23 AM

Undefined index

i have enabled everything i can.. still nothing gives..

You have enabled PHP error reporting in PHP ini I guess.. or SMF does so..(I hope not).
Undefined isnt really an error often, but just means a string is empty.. and it will be when you start new at something (such as blog)

Usually, in PHP5, it means that a variable is empty.. and can be solved by setting a value to it.. 

$i=0; //init temp var  (to prevent emty strings errors, where things havent been properly initialized.)

I usually turn off error reporting, because it isnt really "errors", and will populate the error log at SMF to be HUGE

Add this at bottom of Settings.php if you want to get rid of it all


// Turn off all error reporting
error_reporting(0);

or
ini_set('display_errors', 0)


Will prevent the error log in SMF to get huge with all these petty small "errors" that arent really important..
And its a pain to get all the mod developers to do what PHP really likes (initialize everything)...


I dont really want to see all these "errors" logged.. so that what I do :) I mean, the SMF forum works fine with all my mods.. But its bound to produce a lot of these small "errors" that php reports to log (even if all works fine)

Disadvantage is of course that it turns off ALL error logs.
If you want it only at certain mods/scripts, you can add the stuff at top of the pages, instead of Settings.php


:)






Smoky "Rider" Blue

id rather keep my log clean to start with, that way, should something ever go wrong, i wont have tons of errors to go thru, i will know immediately what did cause the errors and i can fix them, but each to their own..  :)

the blog is a kewl feature and i really do like it.. i might play with it more..  ;)
**Take the time to remember friendships and family.. Sometimes it's all we have, and missed very much**

robbie93


Charles Hill

#433
@ robbie... what is the URL you are going to for the other people's blog control panel?

edit--- and where is the link at that you are clicking?

You should note that the b102 error (the one you're experiencing) occurs for one of two reasons....
1... you are trying to view another user's blog control panel and you are not an admin
2... you are trying to view the blog control panel of a user that does not exist... ie the 'u' request variable IS set AND does not equal to the ID of an existing user in your site.

robbie93

#434
here is the url to the error

http://robbie93andhotchildxox.net/index.php?action=blogControlPanel;u=1;blog=310

here is the url to the control panel

http://robbie93andhotchildxox.net/index.php?action=blogs

I get the error when as admin go to check a members blog

and the member exists :D

at the moment I cant even access the control panel for members blogs I am going to disable the blog because as of now it is worthless :o

this is a really good mod charles but at the moment it has too many bugs in it :-[

Smoky "Rider" Blue

hard to see what you are pointing too robbie, when you have the site disabled for guest viewing..

unless you can provide a temporay access.. ;)
**Take the time to remember friendships and family.. Sometimes it's all we have, and missed very much**

robbie93

thats the thing smoky,   I have it set for guest viewing :-\

I am gonna delete the mod I give up :'( :o


Smoky "Rider" Blue

that isnt the mod doing that robbie..

its your forum setting.. they arent allowing for guests to see the site..
**Take the time to remember friendships and family.. Sometimes it's all we have, and missed very much**

robbie93

I changed it so that guests could view Blogs but it didnt work lol

does the mod work for you smoky?

Charles Hill

@ robbie93... Find "Allow guests to browse the forum" on the following page:
http://robbie93andhotchildxox.net/index.php?action=featuresettings

Advertisement: