UniUploader with DF Port

Dragonfly integration forum

UniUploader with DF Port

Postby Ricomd » Fri Aug 18, 2006 2:00 am

Hello, I was wondering with the DF port of roster, how does one get UniUploader working? What would be the url, and basic setup, etc?

Thank you very much for your time!
Ricomd
WR.net Apprentice
WR.net Apprentice
 
Posts: 13
Joined: Wed Aug 16, 2006 12:41 am

UniUploader with DF Port

Postby jimig1 » Mon Aug 21, 2006 9:30 pm

no it does not it uniuploader needs to accept a cookie to be able to upload so it needs to be updated to do that
User avatar
jimig1
WR.net Apprentice
WR.net Apprentice
 
Posts: 36
Joined: Fri Jul 07, 2006 10:48 pm

UniUploader with DF Port

Postby Anaxent » Sun Sep 10, 2006 7:16 am

Well I think I have stumbled onto something that may get us by for now with UU and posting to DF. With in the cmsinit.inc file I found the function that checks to see if the user has cookies enabled or not so I added a new line to it that would allow the user agent of UU to bypass the check.

cmsinit.inc
search for
Code: Select all
/******************************************************************************
  Check if the <form> POST is comming from this server
*******************************************************************************/
if (!is_user() && $_SERVER['REQUEST_METHOD'] == 'POST' && empty($CPG_SESS['user']['uri'])) 
    {
        if (
PHPVERS >= 43) {
            
trigger_error('<pre>'.print_r($CPG_SESStrue).'</pre>'E_USER_WARNING);
        }
    
cpg_error('Please enable cookies to post on this site. If you feel that you have reached this message in error please go back to the preceding page and post again');
    } 


We will be changing all that code to
Code: Select all
/******************************************************************************
  Check if the <form> POST is comming from this server
*******************************************************************************/
if (!substr($_SERVER['HTTP_USER_AGENT'], 011 ) == 'UniUploader' 
{
    if (!
is_user() && $_SERVER['REQUEST_METHOD'] == 'POST' && empty($CPG_SESS['user']['uri'])) 
    {
        if (
PHPVERS >= 43) {
            
trigger_error('<pre>'.print_r($CPG_SESStrue).'</pre>'E_USER_WARNING);
        }
    
cpg_error('Please enable cookies to post on this site. If you feel that you have reached this message in error please go back to the preceding page and post again');
    }


Unfortanatlly im at work when I stumbled accross this so I have not been able to fully test untill I get home. So all that try this out please post yor results.
User avatar
Anaxent
WoWRoster.net Dev Team
WoWRoster.net Dev Team
 
Posts: 642
Joined: Tue Jul 04, 2006 6:27 am
Location: Phoenix, Az

UniUploader with DF Port

Postby Ricomd » Mon Sep 11, 2006 7:13 am

With the DF port, what would be the URL you'd give the uploader to post to? I am a .NET developer, so I may look at modifying the UU to work better with DF.
Ricomd
WR.net Apprentice
WR.net Apprentice
 
Posts: 13
Joined: Wed Aug 16, 2006 12:41 am

UniUploader with DF Port

Postby Anaxent » Mon Sep 11, 2006 7:42 am

the upload url will be the same url that you would manually upload to

http://domainname.com/index.php?name=wo ... ateProfile

I did get UU to work by making the above adjustment to the cmsinit.inc file and I also had to remove the auth code I had added to the updateProfile.php file.

line 398-416 of updateProfile.php was
Code: Select all
if ($userinfo['username'] == 'Anonymous') {
    include_once(
ROSTER_BASE.'roster_header.tpl');
    include_once(
ROSTER_LIB.'menu.php');
    print 
'<span class="title_text">'.$wordings[$roster_conf['roster_lang']]['upprofile']."</span><br /><br />\n";
     print
            
'<div >
                '
.border('sred','start').'
                <center>Must Be Logged in to use this service!</center>
                '
.border('sred','end').'
            </div>'
;
    include_once(
ROSTER_BASE.'roster_footer.tpl');
    }

elseif( 
$htmlout )
{
    
$header_title $wordings[$roster_conf['roster_lang']]['upprofile'];
    include_once(
ROSTER_BASE.'roster_header.tpl');
    include_once(
ROSTER_LIB.'menu.php');
    print 
'<span class="title_text">'.$wordings[$roster_conf['roster_lang']]['upprofile']."</span><br /><br />\n";
 


and now to allow uu to upload

Code: Select all
if( $htmlout )
{
    
$header_title $wordings[$roster_conf['roster_lang']]['upprofile'];
    include_once(
ROSTER_BASE.'roster_header.tpl');
    include_once(
ROSTER_LIB.'menu.php');
    print 
'<span class="title_text">'.$wordings[$roster_conf['roster_lang']]['upprofile']."</span><br /><br />\n";
 


This is only a fix until we can get cookie handling enabled in UU but it does work.
User avatar
Anaxent
WoWRoster.net Dev Team
WoWRoster.net Dev Team
 
Posts: 642
Joined: Tue Jul 04, 2006 6:27 am
Location: Phoenix, Az

Re: UniUploader with DF Port

Postby aalwein » Wed Sep 13, 2006 6:28 am

by modifiying this code, which I'm assuming is the DF cmsint.inc, are you putting the security of DF at risk? This only disables cookie checks for UU, not any other function of DF correct?
aalwein
WR.net Apprentice
WR.net Apprentice
 
Posts: 25
Joined: Sun Jul 23, 2006 8:41 pm

UniUploader with DF Port

Postby zanix » Wed Sep 13, 2006 6:30 am

It only disables cookies for the 'HTTP_USER_AGENT' = 'UniUploader'

So if someone posts with this user agent, then they can post without authorization
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: UniUploader with DF Port

Postby aalwein » Wed Sep 13, 2006 7:02 am

ok that shouldn't become an issue. the other thing is i can't find updateProfile.php file. what directory is this in?

ok i think there's a new version out and i'm running beta 1 or something. better get beta 2.
Last edited by aalwein on Wed Sep 13, 2006 7:05 am, edited 1 time in total.
aalwein
WR.net Apprentice
WR.net Apprentice
 
Posts: 25
Joined: Sun Jul 23, 2006 8:41 pm

Re: UniUploader with DF Port

Postby Anaxent » Wed Sep 13, 2006 8:45 am

Ok to make UU work with DF I not only had to modify the df core file but also the updateProfile.php

with in this post you can find the modified version of the updateProfile.php file that will allow UU to update the roster.
Attachments
uuupdatepatch.zip
(5.15 KiB) Downloaded 76 times
User avatar
Anaxent
WoWRoster.net Dev Team
WoWRoster.net Dev Team
 
Posts: 642
Joined: Tue Jul 04, 2006 6:27 am
Location: Phoenix, Az

Re: UniUploader with DF Port

Postby RottGutt » Wed Sep 13, 2006 11:46 am

Thanks for getting this to work. My only question now is which file are we supposed to point UniUploader to? There is no wowparser.cgi file in the WoWRosterDF installation.
RottGutt
WR.net Journeyman
WR.net Journeyman
 
Posts: 92
Joined: Sun Aug 13, 2006 12:07 am

UniUploader with DF Port

Postby Anaxent » Thu Sep 14, 2006 10:36 am

you point the UU to http://dowmian.com/index.php and make sure to have 2 additional variables

field1 =name var 1= wowrosterdf
filed2 =file var2= updateProfile
User avatar
Anaxent
WoWRoster.net Dev Team
WoWRoster.net Dev Team
 
Posts: 642
Joined: Tue Jul 04, 2006 6:27 am
Location: Phoenix, Az

Re: UniUploader with DF Port

Postby RottGutt » Thu Sep 14, 2006 6:25 pm

Anaxent wrote:you point the UU to http://dowmian.com/index.php and make sure to have 2 additional variables

field1 =name var 1= wowrosterdf
filed2 =file var2= updateProfile


Ok, no idea how to do that part about the variables. Do these 2 lines go into index.php (I have nothing that looks like those 2 lines in my index.php)? Most of us here need step-by-step instructions for things like that. Would you mind breaking it down into detailed steps for us? Or better yet, when you have a file that needs editing, please include the edited file in the post, so all we have to do is upload it. I know this would not be possible for every file, as some have site specific info in them, but it might save you from a million dumb questions like mine.

RottGutt
RottGutt
WR.net Journeyman
WR.net Journeyman
 
Posts: 92
Joined: Sun Aug 13, 2006 12:07 am

UniUploader with DF Port

Postby Anaxent » Thu Sep 14, 2006 10:15 pm

the variables would need to be added to UU's configuration. If you use UU I would also use UniAdmin as you can set the settings there and have the user sync to it. I will post a few screenshots of what im talking about.
User avatar
Anaxent
WoWRoster.net Dev Team
WoWRoster.net Dev Team
 
Posts: 642
Joined: Tue Jul 04, 2006 6:27 am
Location: Phoenix, Az

Re: UniUploader with DF Port

Postby RottGutt » Thu Sep 14, 2006 11:52 pm

Anaxent wrote:the variables would need to be added to UU's configuration. If you use UU I would also use UniAdmin as you can set the settings there and have the user sync to it. I will post a few screenshots of what im talking about.


Ok, now that you mention that, I have a better understanding of what you are talking about. I am using UniUploader right now to u/l my profile to www.rpgoutfitter.com , and I had to change some things similar to these to make it work correctly. They happen to have step-by-step instructions on their site with screenshots that made the UU configuration very easy. I am assuming that your instructions will be very similar. I look forward to your instructions, and I thank you for taking the time to create them.

RottGutt
RottGutt
WR.net Journeyman
WR.net Journeyman
 
Posts: 92
Joined: Sun Aug 13, 2006 12:07 am

Re: UniUploader with DF Port

Postby RottGutt » Fri Sep 15, 2006 10:54 am

I tried the settings you suggested, but just could not get it to work for me. Looking forward to those instructions!

Does UniAdmin work for DragonFly?
Last edited by RottGutt on Fri Sep 15, 2006 10:59 am, edited 1 time in total.
RottGutt
WR.net Journeyman
WR.net Journeyman
 
Posts: 92
Joined: Sun Aug 13, 2006 12:07 am

Next

Return to Dragonfly

Who is online

Users browsing this forum: No registered users and 0 guests

cron