Vanilla 1 is no longer supported or maintained. If you need a copy, you can get it here.
HackerOne users: Testing against this community violates our program's Terms of Service and will result in your bounty being denied.

Random Quotes ?

2»

Comments

  • Sorry, I didn't speak clearly. Both versions work fine, but what I mean is I didn't manage to add a working language definition for the title in the Panel version. It causes an error if I use the same syntax than for the header version.
  • The problem was fixed, thanks to jimw. The package was updated to version 1.0.1.
  • Great extension, but how come it strips out question marks?

    And fullstops (periods)?
  • edited November 2006
    Well it doesn't exactly strips out question marks. In fact, it doesn't display the last character of a line until you add an empty space at the end. I've no idea why.
    And I didn't notice about fullstops, thanks for pointing this.

    I've written this (with a space at the end):
    Test ? Test ? Test ?
    And it displays this :
    Test ? Test ? Test ?
    If somebody knows a solution...

    Another limitation is it will show a warning if you leave a blank line.
  • I have installed this add-on and am using the Header flavor. It works for the most part fairly well but throws out these errors pretty frequently:

    Notice: Undefined offset: 1 in /home/forum/extensions/RandomQuotesHeader/default.php on line 39

    Notice: Undefined offset: 0 in /home/forum/extensions/RandomQuotesHeader/default.php on line 39

    I am not a PHP programmer so I am not quite sure how to repair those errors.
  • Hey sunmicroman I think you might have a blank line in your TXT file or maybe a non-ASCII character somewhere.
  • Thanks Wanderer

    But this is the line:

    list ($nada, $quote ) = $matches;

    That is how it came installed. I have not modified that line.

    What could be wrong?
  • No not the php file, I meant the text file containing the quotes. I had a non-ASCII character stuffing things up.

    I used "Convert to ASCII" in my text editor and it fixed it.
  • edited November 2006
    Converting to Unicode is actually what fixed it for me.

    Thanks for all of your help!!
  • edited November 2006
    Well, I thought it fixed it. Still get the errors.

    Any other ideas?

    Sure seems to me that if it complaining of a PHP line error in the code than that is what it must be. But I do not know PHP so I cannot tell.
  • Can you send me the quotes.txt file so I can look at it? The problem is that it is complaining about a blank line. I am working on a resolution to this. Thank you. You can email it to jwurster at comcast dot net.
  • It must be that line but that doesnt mean the line is incorrectly written. It means that sometimes while executing that line it fails - since it's sporadic it's fair to assume that it must depend on what variables are being fed into the line. In this situation it's setting the variable $nada to the 0th index of $matches and $quote to the 1st index. Obviously in this case it's failing to find either of those indexes which, as wanderer suggested, would imply it was looking at a blank line. If you're sure you dont have any in your quotes file then I'm a bit confused.
  • Man i spent a long time writing that reply. haha.
  •  Quote: sunmicroman  Sure seems to me that if it complaining of a PHP line error in the code than that is what it must be.
    Nope, the line in the PHP file being referred to, is having trouble with a randomly chosen quote in your quotes.txt file.

    How many lines does it have? Are you able to temporarily remove all but, say 3 lines and see how you go.

    I have about 70 lines in mine, as I said, I had the same error as you, the cause was non-ASCII characters.

    Also it could be a character that needs to be escaped such as a quote?
  • Hi folks! You should no longer get random warnings now: jimw has found a way to get rid of the errors caused by blank lines in the txt file. I've updated the extension to the 1.0.2 version.
  • quick question.. the default vanilla theme has a gradient edge between the side panel and main window. now the text of the random quote seems to bleed slightly into the gradient. check at my site if you don't understand what i'm talking about. (bluebrotherhood.org) so i tried to edit the css file from 180 px wide down 10 than 20 pixels. so that the line would break a l;ttle bit earlier. but nothing changed. and theres nothing in the php file that looks like it would help me. please tell me.. what did i miss? thanks in advance! mike
  • In the default.php file, you'll see towards the bottom, the line: $quotedisplay .= '<br /><p class="quote">' .$quote .'</p>'; Remove the <br /> to bring the quote up closer to the title.
This discussion has been closed.