|
InstallationInstructions
PorPOISe installation instructionsUnzip the release file somewhere on your system. Make the subdirectory "web/" accessible through the web server. If you have server administrator rights you should be able to make a new virtual host or virtual directory for this. If you only have regular user rights and you are on a UNIX-like system you can make a symbolic link ('ln -s') to the "web/" directory from a place in your home directory that is accessible through the web server. If you have only have FTP access or are not on a UNIX-like system you must put PorPOISe into a web-accessible directory but then you MUST change some settings to avoid security issues (see next step). You may also want to take this step to make future upgrades easier. After unzipping/uploading/copying the release files, take the config/ directory and move it someplace where it is not reachable through the web. Remember where you put it and open the file config.php. Change the constant PORPOISE_CONFIG_PATH to where you put the config directory and you should be good to go. From here on we shall refer to this path as "yourconfig". For experimentation, you can leave the config location alone. However, if you store database credentials in the config file, please make sure that the config file is not accessible through the web or you will expose your database password. Open "http://yourhost/yourdirectory/porpoise.php" and check that you get JSON output telling you that the parameter "userId" is missing. If you see this, PorPOISe works. If you get a 404 error, check your paths. If you get a 403 error, check your file permissions. Note: your browser may want to save the JSON output as a file to disk rather than open it directly. If you save the file, open it in a text editor and then see JSON, everything is good. You are now set up to create layers. The README file has more details on creating layers in the config file. If you plan to use the dashboard, generate a password for user "default" (or the username of your choice) and store it in "web/dashboard/users.inc.php". You can use the tool in web/dashboard/crypt.php to generate passwords. If you plan to use the dashboard in conjunction with XML files, you have to make your XML files writable for the web server. You can make the files writable by all if you trust all users on your system to behave, othwerwise you have to come up with a more restrictive setup (such as granting only rights to the web server user through ACLs or assigning the files to the web server's group and granting group write permissions). Create and configure your layer on dev.layar.com (if you didn't already), use the web location of porpoise.php as your POI URL and see what it looks like! The dashboard is accessible as http://yourhost/yourdirectory/dashboard/ |
Quote: If you plan to use the dashboard, generate a password for user "default" (or the username of your choice) and store it in "web/dashboard/users.inc.php".
Needs more explanation please...
") or execute "crypt.php". @package PorPOISe @subpackage Dashboard / $access = array(); $access["admin"] = '';
Needs to be changed to what???
Thanks
@freeworldmaps see the example for the web based crypt tool. Please note that this version of Crypt is not yet part of the latest 0.51 releae, so you may want to get the latest version from SVN:
http://porpoise.googlecode.com/svn/trunk/web/dashboard/crypt.php
Downloaded porpoise 0.51 and got the same issue. Works like a charm with the latest crypt.php version. Thanks jsixpack.
Uploaded porpoise 7.1 and tried to access porpoise.php, received the following error: Parse error: parse error, unexpected '{' in /home/content/..../web/porpoise.php on line 36
Do you know what the problem is?
Thanks
Are you running PHP 5 on your machine?
Upgraded the system from 4.x to 5.x and problem solved :)
Thanks for the quick and correct reply
Another quick question, in the Sample database layer configuration, the password and user are not very clear. I filled it in like this: Sample database layer configuration
Is it correct? I cant connect to the DB... Thanks
It looks okay. Can you connect to the database from the command line using the same hostname, dbname, username and password?
hi all, I ahve a problem: I follow all the instructions, everything work fine until I access dashboard. I get this page:
Log out - Home Welcome to PorPOISe
Developer ID xxxx Developer key xxxxxxxx Layers:
And then the page stops here, after "layers". Is it normal? How can I manage info about my layer without manually editing .tab file?
thanks bye
The Dashboard is not yet able to create layers, you'll have to edit config.xml to do that. Once you have created a layer it should show up.
Thank you!
Do you maybe also have a standard example of the value of the following parameter in example.tab? Just the mandatory ones..
Some element (like type or attribution) are not so intuitive, and I can't find any reference about them to put the right value.
thanks
actions alt attribution dimension id imageURL lat lon line2 line3 line4 baseURL full reduced icon size relativeAlt title angle rel scale type
Hi, what is the meaning of the following error string: "Database error: could not find driver"? Cheers,
@alessandro this means that your PHP version is lacking the database driver for the database you're trying to open. Ask a sysadmin to install the driver or Google for instructions on how to install the driver for your system if it's your own machine
Thanks for your support. The point is that my PHP module (working on localhost) does support MySQL. I have other PHP applications which make use of the MySQL database. Any idea? Cheers,
PorPOISe uses PDO (PHP Data Objects), a database abstraction layer. It's possible that the regular MySQL module is installed but not the PDO MySQL module
Ok, I will look for it. Thanks,
I've created a symbolic link as per the instructions but am getting permission denied when attempting to open in the browser. Have used:
for the link. Even tried chmod 777 on the directory. Sorry am a bit of Nubie!fixed it. Apache didn't have access to my /home/porpoise directory
Would anyone be will to setup porpoise for me on my server for a fee?
I'm getting this error when trying to access my /web dir.
Notice: Undefined index: layerName in /homepages/15/d125658886/htdocs/webPublic/layar/porpoise/poiserver.class.php on line 360
Warning: Cannot modify header information - headers already sent by (output started at /homepages/15/d125658886/htdocs/webPublic/layar/porpoise/poiserver.class.php:360) in /homepages/15/d125658886/htdocs/webPublic/layar/porpoise/poiserver.class.php on line 235 {"layer":"unspecified","errorCode":20,"errorString":"Missing parameter: userId","hotspots":,"nextPageKey":null,"morePages":false}
The page you opened expects a "layerName" GET parameter and kind of chokes on it not being there. It should not affect communication between the Layar client and your PorPOISe server but I'll fix it for the next release
Is it possible to upgrade from 0.71 version to 1.0 without copying and pasting all the data? How does the "copy layer" function inside porpoise 1.0 works?
hello, i'm getting some troubles while installing porpoise 1.0. i'm working on ubuntu (LAMP installed) and i've put all my files into /var/www/porpoise (/var/www is web-accessible) then i didn't move (for now) the config folder so the config.php is not altered and i've made web folder readable (typed $sudo chmod 777 web on my console). ok...so i try to connect to http://localhost/porpoise/porpoise.php but i get 404 error.
could someone help me please? thank you
有個問題~就是在資料庫中輸入中文資料,在拉亞介面會出現亂碼
Hello theceic, just got back from vacation. The porpoise.php file is in the web/ directory, so you can set up a virtual host or symlink that only exposes that directory. In your case I reckon the URL should be http://localhost/porpoise/web/porpoise.php
Why Im getting a "Fatal error: Cannot redeclare class HttpRequest? in /../httpdocs/labs/layar/httprequest.class.php on line 18 ??
I pretty sure I have PHP5 enabled. That error show up every time I try to access: "../web/porpoise.php"
any ideas? Thanks
btw, I've just downloaded ur latest version... porpoise_1.0.zip (Release 1.0: Layar 4.0 compatible) and follow ur instructions (I havent setup the DB yet but I dont think its related to that error) Thanks in advanced.
Hello all, Ive been trying to get my installation to work and I'm at complete loss. Don't know what to do from here. I'm no coder or developer but I know enough to usually get things working and modify scripts to fit what I'm doing. We use Hoopala now and its great but I cant download and backup the database because its provided by them. I need to use this with our existing "site store locator(which I already heavly modified)" database seen here http://www.givebackusa.com/literadius/golf_locator.htm (use zip 34683). My problem is I can't even get porpoise to install properly to start. I unzipped and uploaded as per instructions and I'm on a GoDaddy? shared hosting account with php5 and this is what i get:
Warning: require_once(/config//config/template.php) [function.require-once]: failed to open stream: No such file or directory in /home/content/n/i/c/nickg6204/html/givebackusa/porpoise/web-app.class.php on line 17
Fatal error: require_once() [function.require]: Failed opening required '/config//config/template.php' (include_path='.:/usr/local/php5/lib/php') in /home/content/n/i/c/nickg6204/html/givebackusa/porpoise/web-app.class.php on line 17
here is my path to see for yourself: http://www.givebackusa.com/porpoise/web/porpoise.php
Contact me here or westechmail@yahoo.com
Hello to all, I'm the same problem, trying porpoise 1.0 in my localhost i get the following message:
Warning: require_once(..\config\template.php) [function.require-once]: failed to open stream: No such file or directory in C:\wamp\www\AR\porpoise\web-app.class.php on line 17
Fatal error: require_once() [function.require]: Failed opening required '..\config\template.php' (include_path='.;C:\php5\pear') in C:\wamp\www\AR\porpoise\web-app.class.php on line 17
I know it's a "path problem", but i can't resolve for myself. I need help please!
Thanks.
P.D. Sorry for my poor english.
Hi,
Unless you moved directories around, the default path configuration should work. So
define("PORPOISE_CONFIG_PATH", "config");should be what your config.php should look like. If you moved the config directory you should adjust the path accordingly, but that depends on your specific setup.
On another note, I'm not sure what the problem is with the redeclaration fo the HttpRequest class, I've never seen that before...
I installed correctly Porpoise, but I only save new POI in example.xml file with the connector XMLPOIConnector.
I need to change to work with the DB created with "Database.sql" but did not know what else I have to set.
Of course I installed and changed the config.xml file in the section "Sample database layer configuration" according to installation instructions.
Thanks for your help
Hi:
I discover the problem. In the config.xml file, the group sentences of bbdd is comment.
I've finally managed to work fine to porpoise.
Thanks
Hello I've worked on the installation for CMS. But I've one problem that I can't solved until now. In CMS is system in DB: id and value.
For example: id | value
longitude | 42.45678 latitude | 12.12345
But in your program is it in one row. id, longitude, latitude, ...
Is there any solution to change the CMS system to your using sqlconnector. One sql command or php script?
The best solution is one row command to the db, but is it possible?
hi there,
i'v installed the latest version of porpoise. i get an error if i open my layer with Layar browser: "expect timestamp", but if teste it in Layar test enviroment it works fine. Any ideas? best regards, Nelson
correction. the eror is "Missing parameter: Timestamp"
The timestamp thing was a bug, it has been fixed in 1.0a
How would I create a new layer? I only see the example layer. I can add many new POIs instead... :(
duplicate the configuration details for the example layer (the <layer> and </layer> tags and everything in it) but change the layer name and a the data source (file name or database)
Isn't the developer-id and key required no more? http://devsupport.layar.com/entries/420922-where-can-i-find-my-developer-id-and-key
You are absolutely right, thanks for pointing that out
Have an run question:
Am running Apache 2.2 with PHP 5.3.6 on Windows 7 box (no IIS).
Installed Porpoise 1.1a Looked at the config.php file and left the default setting to "config"
Tried the following url:
Http://localhost/porpoise.php in Firefox Browser 4.0.1
Got a 404 error message.
Changed the config.php to the following:
if (!defined('PORPOISE_CONFIG_PATH')) {
Tried the following url again:
Http://localhost/porpoise.php in Firefox Browser 4.0.1
JSON Support is enabled as shown in PHPINFO.php version JSON 1.2.1
Anyone see anything that I am doing wrong?
Thanks,
Lenny
@Lenny
Try pointing your browser to http://localhost/porpoise/web/porpoise.php
When I use the above url for localhost, in Firefox, I get a dialogue box with the following statement "You have chosen to open porpoise.php which is a: PHP file from: http://localhost
What should Firefox do with this file?
I know that this is a path issue, but for the life of me, I cannot find it.
It is though where the path is set in either the config.php or the template.php is not recognized somehow.
I add the path to the C:\\Java\\Apache2.2\\htdocs\\porpoise\\config in my global environment variables and still got the same results.
I am baffled at this point. :(
RE: Firefox and file download prompt "You have chosen to open porpoise.php..." I got that too. Then I tried in IE and found that opening the file is what looks to be the JSON file. So from what I can tell, that may be a good sign that it is working.
That's correct. Depending on your browser (and installed add-ons) it may try to save the outputted JSON to a file rather than display it
Yeah, I believe you are right. I set the chdir(dirname(FILE) . "/.."); in the porpoise.php file to echo and got the following with the prompt to open porpoise.php with the following write out.
c:/java/config{"layer":"unspecified","errorCode":20,"errorString":"Missing parameter: userId","hotspots":,"nextPageKey":null,"morePages":false}
So, I think I had success, but I am not sure what the errorCode:20 is though.
This was performed in Firefox 4.0.
It does however find the path as the path is shown in the Echo.
Thanks for your response.
Lenny
Quote: If you plan to use the dashboard, generate a password for user "default" (or the username of your choice) and store it in "web/dashboard/users.inc.php".
Needs more explanation please...
") or execute "crypt.php". @package PorPOISe @subpackage Dashboard / $access = array(); $access["admin"] = '';
Needs to be changed to what???
Thanks
total newbie question -- i just installed: dashboard refuses to let me login ("Invalid username or password") even with 'default' user and blank password
all permissions are set 755
users.inc.php contains: $access = array(); $access["default"] = '';
i generated other users and passwords with crypt inserted them into users.inc.php they too do not work
hints?
passwords in users.inc.php are always hashed, so the empty string there does not correspond to a blank password. A valid hash for a blank password is actually $1$DY1cnmv7$AdReZVzR6pLpdobi8WKuX0
Not sure if anyone else still has the 'username + password' issue, but here's what I did to quickly get around it....
make a new key $access["USERNAME"] = crypt("PASSWORD");
Where USERNAME is whatever you want to enter into the username field of the login form, and PASSWORD is whatever you want to enter into the password field of the login form.
Hope this helps someone.
Yes, that works too. The downside is that you are storing your passwords in plain text. If someone else has access to the users.inc.php file, your password is compromised. If you take this approach, I urge you to pick a password that you do not use elsewhere.
Hello @all,
i'm new(bie) to PorPOIse - i just installed (after many solving steps) and succeded to log in (dashboard) but the porpoise.php page give this feedback: it asks me to download the php page! Sample Image linked:
Where i'm wrong? Happy if someone could help. ThanX in Advance! SpriteHat?
Hello, i downloaded the php file, opened and this is the output
{"layer":"unspecified","errorCode":20,"errorString":"Missing parameter: userId","hotspots":,"nextPageKey":null,"morePages":false}
THNX SpriteHat?
That's exactly what you need to see, it means PorPOISe is executing just fine, it is now expecting requests from Layar. See the README http://code.google.com/p/porpoise/source/browse/trunk/README for more details on how to create layers so you can view them on your phone
@azrobit i did what you said but im still having trouble logging in, not sure what i did wrong, anyone help??
nevermind figured it out, here is how i solved it;
I want the password to be "example" So I issue a http request: http://localhost/porpoise/web/dashboard/crypt.php?arg='admin' I get a string: $1$tOmmzX8S$zLW/kxuIkeQ.FWIWVDcYI/ So I edit users.inc.php: $access["default"] = '$1$hE/.fB4.$jSBxNJ/BSLGebuiBddwvi1'; I now go to http://localhost/porpoise/web/dashboard/ and enter password "admin" and submit
and it worked
This is sweet. Sunday I hear about Layar. And by Tuesday morning - after maybe 4 hours spent on it - I have my first working augmented reality layer up and working on my iPhone. Cool. My wife is underwhelmed of course :)
I think, porpoise is amazing! Works perfectly. Thank you very much!
Can we expect a update arround API v6? That would be more then awesome!!
Hi,
I get the same warning some others get: Warning: require_once(/config//config/template.php) function.require-once?: failed to open stream: No such file or directory in /home/content/n/i/c/nickg6204/html/givebackusa/porpoise/web-app.class.php on line 17
(I just copy/pasted the warning of someone else here for security reasons).
I've put config outside of my www folder and put the home directory where the config folder is in config.php like this:
Also tried with or without the slashes, gave everything 777 rights just to be sure, makes no difference. Am I missing something?
For those having password problems, do this:
@Cuttofan you should not replace "PORPOISE_CONFIG_PATH" in the define() statement, but "config", like so
define("PORPOISE_CONFIG_PATH", "/myconfig/");
where you replace /myconfig/ with the actual path to your config directory
hi,
everything works great! Found only one issue and not sure if this is important! I loaded the sql in and it gives me an error on the constraints:
/* SQL Error: Can't create table './databasename/#sql-104e_180a0c.frm' (errno: 150) */
for the table 'Action' and 'Animation'
original code:
{{{-- Constraints for table action -- ALTER TABLE Action
-- -- Constraints for table animation -- ALTER TABLE Animation
i can not find out what goes wrong! Anyone?
Hi everyone , i'm totally newbie with php and all this but i wanted to try.
Everything is online and working to login at dashboard,
So i now only see , layar : example , i'm not able to add new layar?
If i wanted to add POI at that layar that worked , but online entering at dev.layar.com it didn't show my newly added POI
Probably i'm doing something wrong, maybe with the names of my layar at dev.layar.com , should it be the same name as the layar ? but example is already taken of course.
Can someone explain me how all this works with dashboard , maybe with small tutorials or something , i can feel i'm almost there :-))
or maybe not .... :-))
Greetz
It's not possible to add layers through the dashboard yet, you'll have to edit the config.xml file for that
I uploaded porpoise but cannot login to the dashboard-I do not know what to do. I am not sure if I configured it wrong. I have yahoo so no php5. http://elainereiter.com/porpoisee/web/dashboard/index.php user and or password=invalid?
http://elainereiter.com/porpoisee/web/dashboard/users.inc.php page/passwords?
$access = array(); $access["default"] = 'poo'; $access["moon"] = '$sillypuppy1'; $access["pigg"] = '$1$plJdhG2e$dXuo.6QpxTFMjENjnnhbk/';
poi: http://elainereiter.com/porpoisee/web/porpoise.php I could not/did not know how to generate the passwords in the cript page either so I made them up. Well-is this fixable or not an option because I do not have php5? Thank you, Elaine Reiter admin@elainereiter.com elaine@elainereiter.com
Awesome tool for easily creating layers!! I just read that it should be possible to create Layar Visions, but I wonder how? Do you have an example or some documentation how to do that? Changelog just says:
When I test my layer in Layar, I get this:
error validating provider response - Traceback (most recent call last): File "/var/www/layar.com/app/api/handlers/api_layer/mainproxy.py", line 85, in validate_response data = validator.validate(response_as_dict, schema) File "/var/www/layar.com/app/api/jsontransmogrifier.py", line 560, in validate raise ValidationError?(message=", ".join(self.errors), errors=self.errors) ValidationError?: Value u'' for field 'biwStyle' is not in the enumeration: ['classic', 'collapsed']
I think that there is some problem with de biwStyle, but I can't find which one...
I have the same problem testing my layer!!! Any idea???
When I test my layer in Layar, I get this:
error validating provider response - Traceback (most recent call last): File "/var/www/layar.com/app/api/handlers/api_layer/mainproxy.py", line 85, in validate_response data = validator.validate(response_as_dict, schema) File "/var/www/layar.com/app/api/jsontransmogrifier.py", line 560, in validate raise ValidationError??(message=", ".join(self.errors), errors=self.errors) ValidationError??: Value u'' for field 'biwStyle' is not in the enumeration: ['classic', 'collapsed']
I think that there is some problem with de biwStyle, but I can't find which one...
Anyone knows about this error?
Error. Parsing JSON Request failed.<br /> <b>Fatal error</b>: Allowed memory size of 33554432 bytes exhausted (tried to allocate 71 bytes) in <b>/home/zarulumb/public_html/wp-includes/class-simplepie.php</b> on line <b>9166</b><br />
Somehow the "Default BIW Style" option is not being saved!
The result being the outputted (empty) value does not conform to the spec.s <http://layar.pbworks.com/w/page/28473525/GetPOIs-JSON%20Response> Forces the BIW style for all POIs to a certain form (verbose "classic" or lean "collapsed"). Set to null or do not send for default behavior, which is "classic" for geolocated POIs and "collapsed" for feature tracked POIs.
In my case this meant I had to manually edit the database table "Layer" and set the biwStyle field to classic.
It nevertheless seems evident that there is a bug. This should be saved when you set it in the Dashboard .