Topics

User Functions

Events

There are no upcoming events

What's New

Stories

1 new Stories in the last 2 weeks

Comments last 2 weeks

No new comments

Trackbacks last 2 weeks

No new trackback comments

Links last 2 weeks

No recent new links

NEW FILES last 14 days

No new files

Welcome to Geeklog Friday, May 24 2013 @ 03:39 PM EDT


 Forum Index > Extensions > Plugins New Topic Post Reply
 upage v 2.0 released!
First | Previous | 1 2 3 | Next | Last
   
amckay
 01/26/04 10:33AM (Read 10039 times)  
+++++
Full Member

Status: offline


Registered: 03/23/02
Posts: 180
Hey folks,

My upage plugin now has its own native photo upload, with an easy way to include photos in pages without knowing HTML. There is also support for 'plain text' pages for people who do not know HTML.

Be sure to read all of the below very carefully! And be sure to edit the plugin's config.php after installing but before using!

http://www.bodensatz.com/upage/?page=readme
http://www.bodensatz.com/upage/?page=install
http://www.bodensatz.com/upage/?page=help

cheers,
-Alan

 
Profile Email Website
 Quote
amckay
 01/26/04 01:05PM  
+++++
Full Member

Status: offline


Registered: 03/23/02
Posts: 180
BTW, if you wish to try it out please use this site for testing :

https://secure.neap.net/

and not my beer site.

 
Profile Email Website
 Quote
noke
 01/26/04 01:17PM  
+++--
Chatty

Status: offline


Registered: 10/22/03
Posts: 37
*laffs* sorry

http://www.worldclubdjs.com
 
Profile Email Website
 Quote
ronack
 01/26/04 02:41PM  
+++++
Full Member

Status: offline


Registered: 05/27/03
Posts: 602
Got an error on install

Template Error: filename: file ./F:/geeklog/plugins/upage/templates/install.thtml does not exist.
Halted.

 
Profile Email
 Quote
amckay
 01/26/04 02:51PM  
+++++
Full Member

Status: offline


Registered: 03/23/02
Posts: 180
Here is your random photo block.

Put it in /path/to/geeklog/plugins/upage/functions.inc

It will be there by defaut in the next release

PHP Formatted Code

function phpblock_UPIC_random()
{
        global  $_TABLES;
        global  $_CONF;
        global  $LANG_UPAGE;

        $num    = DB_count( $_TABLES['upic'] );
        $pic    = mt_rand( 1, $num );

        $sql    = "SELECT *, 'center' as xalign, 'phpblock' as xmode, "
                        . " 'small' as xscale, 1 as xlink "
                        . " FROM {$_TABLES['users']}, {$_TABLES['upic']} "
                        . " WHERE {$_TABLES['users']}.uid = {$_TABLES['upic']}.upic_uid "
                        . " ORDER BY {$_TABLES['upic']}.upic_uploaded DESC LIMIT " . $pic;

        $result = DB_query( $sql );
        if ( ! $result )
                return;
        while ( $pic = DB_fetchArray( $result ) )
                $myPic  = $pic;

        $retr   = UPIC_Show( $myPic );

        return $retr;
}


 


 
Profile Email Website
 Quote
amckay
 01/26/04 02:53PM  
+++++
Full Member

Status: offline


Registered: 03/23/02
Posts: 180
Quote by ronack: Got an error on install

Template Error: filename: file ./F:/geeklog/plugins/upage/templates/install.thtml does not exist.
Halted.


Interesting. I'll look into it. May be a windows problem.

 
Profile Email Website
 Quote
amckay
 01/26/04 02:55PM  
+++++
Full Member

Status: offline


Registered: 03/23/02
Posts: 180
I think it has to be either a permissions problem on your end, or you installed it incorrectly. I checked the original distribution and it contains that file (and a bunch of junk I do not need so will delete on the next release ;-)). Check the last item below. The file is the same one you downloaded :

heimat# tar tzf /home/www/secure.neap.net/vdirs/download/upage20.tar.Z | grep template
plugins/upage/templates/
plugins/upage/templates/display-default.thtml
plugins/upage/templates/admin.thtml
plugins/upage/templates/index.thtml
plugins/upage/templates/blank.thtml
plugins/upage/templates/admin-functions.thtml
plugins/upage/templates/header.thtml
plugins/upage/templates/one-row.thtml
plugins/upage/templates/user-functions.thtml
plugins/upage/templates/user-prefs.thtml
plugins/upage/templates/one-row2.thtml
plugins/upage/templates/install.thtml

 
Profile Email Website
 Quote
ronack
 01/26/04 03:26PM  
+++++
Full Member

Status: offline


Registered: 05/27/03
Posts: 602
To me it looks like it put in a ./ in front of the path. Where would it do that?

 
Profile Email
 Quote
ronack
 01/26/04 03:36PM  
+++++
Full Member

Status: offline


Registered: 05/27/03
Posts: 602
On your instruction page it doesn't point to upage20 (you might want to change that), so I downloaded that replaced all the files and received the same error. Still looks like a stray ./ in front of the path.

 
Profile Email
 Quote
TechSys
 01/26/04 05:06PM  
++++-
Regular Poster

Status: offline


Registered: 12/02/03
Posts: 90
Just received the plugin. I will be attempting to do an upgrade this evening. I will let you know if any problems or whatnot.

http://70.145.174.180/
 
Profile Email Website
 Quote
TechSys
 01/26/04 05:30PM  
++++-
Regular Poster

Status: offline


Registered: 12/02/03
Posts: 90
O.k. I just tried upgrading it... didnt work.. I also tried installing it which also didnt work. Here is the error
Template Error: filename: file ./C:/Aeonserv/geeklog/plugins/upage/templates/install.thtml does not exist.
Halted.

When I did the 1.2 install, I had to edit install.php and delete that line, then run the install again. After running the install, I put that very same line back into place and everything worked. This does not happen with 2.0, not sure why.

running upgrade.php, I get the following:
Your upage version : 2.0
Current upage version : 2.0
This is the upgrade program for the upage plugin. It will make some changes to your upage table (one new field for 1.1, one more for 1.2), so please be sure to back up your database before running it, just in case

If you did not already unpack the tarfile to overwrite your previous installation, please do so now.

Full installation instructions are here : http://www.bodensatz.com/upage/?page=install

VERY IMPORTANT
This program only upgrades one upage version at a time. This means that you have to return to this Uprade Home and clicking on the recommended upgrade below, until you finally get the message 'no upgrade required'. So if you are currently using version 1.0, you will see 'Upgrade from 1.0 to 1.1'. You click it and when you return to this page, you will see 'Upgrade from 1.1 to 1.2' and so on. Keep doing this until you see 'no upgrade required'

No upgrade required.

So there shouldn't be any problems, right...wrong. when I click on the upage link I get a blank screen.

I am gonna play around with it and see what's up. I may even get rid of 1.2 all together, then try installing 2.0.. Will let ya know what happens (If I get time to do anything)

http://70.145.174.180/
 
Profile Email Website
 Quote
amckay
 01/26/04 07:08PM  
+++++
Full Member

Status: offline


Registered: 03/23/02
Posts: 180
upage.tar.Z is softlinked to upage20.tar.Z - same thing

You windoze guys - get a real OS would ya's ;-)
I tested both the fresh install and the upgrade on my UNIX system and they both worked fine. Tested on 2 different websites.

Send me your /path/to/geeklog/plugins/upage/config.php after you edited it as well as your regular geeklog config.php and I'll figure it out.

cheers,
-Alan

 
Profile Email Website
 Quote
amckay
 01/26/04 07:13PM  
+++++
Full Member

Status: offline


Registered: 03/23/02
Posts: 180
Quote by TechSys:running upgrade.php, I get the following:
Your upage version : 2.0
Current upage version : 2.0


Before you did anything? Very odd.

The first one gets pulled out of the DB, the second is hardcoded in the script. Check your 'plugins' table in your DB to see what version number is in there.

 
Profile Email Website
 Quote
amckay
 01/26/04 07:23PM  
+++++
Full Member

Status: offline


Registered: 03/23/02
Posts: 180
Quote by ronack: To me it looks like it put in a ./ in front of the path. Where would it do that?


The path in question is compiled thusly

$_CONF['path'] . 'plugins/upage/templates/install.thtml'

So what is your $_CONF['path'] set to?

 
Profile Email Website
 Quote
amckay
 01/26/04 07:57PM  
+++++
Full Member

Status: offline


Registered: 03/23/02
Posts: 180
I'm going to rewrite that code to get rid of the template. I don't like templates, anyway, and this is one of the few pieces of code I just used verbatim from someone else. If the kids stay calm I may have it ready later this evening ;-)

 
Profile Email Website
 Quote
amckay
 01/26/04 08:20PM  
+++++
Full Member

Status: offline


Registered: 03/23/02
Posts: 180
OK, evil templates now gone.

Replace your install.php with this file :

https://secure.neap.net/download/install.txt

(rename it .php obviously)

And if it works I'll update the tarball download to include it. Worked fine on my UNIX system.

 
Profile Email Website
 Quote
destr0yr
 01/29/04 04:55AM  
+++++
Full Member

Status: offline


Registered: 07/06/02
Posts: 324
I was getting an error that file_get_contents (line 16 of include.phpi) was an undefined function. Low and behold, it only came into existance in PHP4 >= 4.3.0. My host has 4.2.x

To fix it, i added the following above line 16, as suggested at http://ca2.php.net/file_get_contents
PHP Formatted Code

if (!function_exists("file_get_contents")) {
          function file_get_contents($filename, $use_include_path = 0) {
            $data = ""; // just to be safe. Dunno, if this is really needed
            $file = @fopen($filename, "rb", $use_include_path);
            if ($file) {
              while (!feof($file)) $data .= fread($file, 1024);
              fclose($file);
            }
            return $data;
          }
        }

 



-- destr0yr "I love deadlines. I like the whooshing sound they make as they fly by." -- Douglas Adams
 
Profile Email Website
 Quote
amckay
 01/29/04 05:33PM  
+++++
Full Member

Status: offline


Registered: 03/23/02
Posts: 180
OK, but your DB will not be populated with the readme, install and most importantly help page

 
Profile Email Website
 Quote
amckay
 01/29/04 05:58PM  
+++++
Full Member

Status: offline


Registered: 03/23/02
Posts: 180
Whoops, sorry - my bad. Yes, that will fix it. I'll add that to my code

 
Profile Email Website
 Quote
destr0yr
 01/29/04 07:27PM  
+++++
Full Member

Status: offline


Registered: 07/06/02
Posts: 324
also, on any image upload, i get the following errors:

PHP Formatted Code

Warning: fopen("/homepages/12/d88571136/htdocs/okg/public_html/upage/upic/2/Picture007.jpg", "r") - No such file or directory in /homepages/12/d88571136/htdocs/okg/plugins/upage/functions.inc on line 1100

Warning: Cannot use a scalar value as an array in /homepages/12/d88571136/htdocs/okg/plugins/upage/functions.inc on line 932

Warning: Cannot use a scalar value as an array in /homepages/12/d88571136/htdocs/okg/plugins/upage/functions.inc on line 933

 

the file is successfully saved, but its telling me that it doesnt exist, when in fact it does? i set perms to 777 just to test...
uhh... yah...
one last (nitpicky) thing, if images have spaces, it borks... maybe something that removes the spaces and renames the file?

-- destr0yr "I love deadlines. I like the whooshing sound they make as they fly by." -- Douglas Adams
 
Profile Email Website
 Quote
First | Previous | 1 2 3 | Next | Last
Content generated in: 1.01 seconds
New Topic Post Reply

Normal Topic Normal Topic
Sticky Topic Sticky Topic
Locked Topic Locked Topic
New Post New Post
Sticky Topic W/ New Post Sticky Topic W/ New Post
Locked Topic W/ New Post Locked Topic W/ New Post
View Anonymous Posts 
Able to post 
Filtered HTML Allowed 
Censored Content