Interesting and puzzling issue

A signature and avatar generator addon

Moderator: zanix

Interesting and puzzling issue

Postby Adariel » Sat Jul 29, 2006 8:55 pm

so you may remember me from the previous board ... had garbled junk for images instead of nice pretty ones? Well, I DL'd WR 1.7.0, put it in a clean install with a fresh DB ... voila - everything works nicely.

So I start poking around, checking everything after EVERY change. I was trying to figure out how to get my membersList tables to be all the same width. I found the code for creating the borders, changed it ever so slightly to allow for a width variable. Boom ... sigs stop working.

Here's what I changed:
in lib/commonfunctions.lib.php:

find:
Code: Select all
function border($style,$mode,$header_text=null)


replace with:
Code: Select all
function border($style,$mode,$header_text=null,$wide)


find:
Code: Select all
    global $roster_conf


add after:
Code: Select all
    if ($wide == '') { $wide 1; } 



find:
Code: Select all
    $start '
<!-- START [open-'
.$style.] container -->
<
table cellspacing="0" cellpadding="0" border="0"


replace with:
Code: Select all
    $start '
<!-- START [open-'
.$style.'] container -->
<table width="'
.$wide.%" cellspacing="0" cellpadding="0" border="0">


I even tried only changing the last part to
Code: Select all
    $start '
<!-- START [open-'
.$style.] container -->
<
table width="100%" cellspacing="0" cellpadding="0" border="0"


Now at least on that one, the avatars show up ... just the signatures are garbled. And of course I don't want ALL my tables to be 100% wide :/


Now for the really odd part:
When I take out the changes and resave the file, the images still don't come back. I have to actually reupload the original file from the zip package for SigGen to go back to normal.

I'm really at a loss here. I'd like to make some minor changes, but if I can't even change the width of a table without SigGen going awol on me, then I'm kinda fubar'd.
Last edited by Adariel on Sat Jul 29, 2006 9:02 pm, edited 1 time in total.
User avatar
Adariel
WR.net Apprentice
WR.net Apprentice
 
Posts: 36
Joined: Tue Jul 25, 2006 9:14 am

Interesting and puzzling issue

Postby zanix » Sat Jul 29, 2006 10:00 pm

What i'd do is replace all the files in roster from the zip package

It's possible you may have messed more up than what you think...


As for your "wide" changes, the function define really should be this
Code: Select all
function border($style,$mode,$header_text=null,$wide=null)

To make it compatible (code wise) with calls to border() that won't use that parameter
Read the Forum Rules, the WiKi, and Search before posting!
WoWRoster v2.1 - SigGen v0.3.3.523 - WoWRosterDF
User avatar
zanix
Admin
Admin
WoWRoster.net Dev Team
WoWRoster.net Dev Team
UA/UU Developer
UA/UU Developer
 
Posts: 5543
Joined: Mon Jul 03, 2006 8:29 am
Location: Idaho Falls, Idaho
Realm: Doomhammer (PvE) - US

Re: Interesting and puzzling issue

Postby Adariel » Wed Aug 02, 2006 10:54 am

ok ... did as suggested ... actually went thru this 3 times trying to figure it out.

First couple of times had mixed results ... the code change worked great and looked how I wanted, but SigGen wouldn't keep me logged in, then wouldn't show the images.

Third time I tried something different. I've been using my editor's "open from FTP" function to change the actual files on the server. The only odd thing I've noticed on it is that it double spaces everything ... which is annoying as hell and I'm trying to figure out how to change. Anyhoo ...

The third time, I opened the files (commonfunctions and memberslist) from my computer, saved copies, uploaded the copies using regular WS_FTP. Now everything works fine - layout looks how I want, SigGen logs me in and holds the cookie, and shows the images.

<sigh>

Now I'm wondering what the editor is doing that fubar's it ... something about the spacing I'm sure. I may be back later, but thanks for the help. It's comforting to know that it wasn't my code being stupid ... just my editor.

p.s. and I'm also wondering if that might be the cause of the similar cookie related errors I was posting about before this board went down ... sometimes I hate technology.
Last edited by Adariel on Wed Aug 02, 2006 10:56 am, edited 1 time in total.
User avatar
Adariel
WR.net Apprentice
WR.net Apprentice
 
Posts: 36
Joined: Tue Jul 25, 2006 9:14 am

Interesting and puzzling issue

Postby zanix » Thu Aug 03, 2006 4:37 am

That's cool, glad you figured it out

I dunno about the editor...I usually DL a copy first, edit it, then upload the edited file
I've never heard of being able to use an editor to edit files directly over ftp, sounds cool
Read the Forum Rules, the WiKi, and Search before posting!
WoWRoster v2.1 - SigGen v0.3.3.523 - WoWRosterDF
User avatar
zanix
Admin
Admin
WoWRoster.net Dev Team
WoWRoster.net Dev Team
UA/UU Developer
UA/UU Developer
 
Posts: 5543
Joined: Mon Jul 03, 2006 8:29 am
Location: Idaho Falls, Idaho
Realm: Doomhammer (PvE) - US


Return to SigGen

Who is online

Users browsing this forum: No registered users and 0 guests

cron