Jonojamesmac Posted April 15, 2009 Share Posted April 15, 2009 (edited) iPhone/iPod Touch Web App for Oscommerce This web app for Oscommerce allows you interface with your shops orders, current features are: - View order list - View orders, including order status, products, attributes, total cost and custommer/order comments. - iWebKit has been incorporated to allow a smoother feel app - Views like a normal app from the Apple App Store - iPhone interaction, call or email a customer with a click of a button. - Google Maps Integration, find where your customer is in 1 click. - Customize it to how you want it. - And more... Please see the readme.txt file included for instructions on how to make it like a full app, as it just needs a few steps by you for it to work as intended. Because it is a web app this is needed. Download here... Just a note that i am just a beginner in the php world, and this was the first thing i've made that does work. The code could be cleaned up a lot but as i learn, i'll learn how to clean it up :) If you have any problems, i'll try to help in the best way possible. Thanks Edited April 15, 2009 by Jonojamesmac Quote Link to comment Share on other sites More sharing options...
Jonojamesmac Posted April 15, 2009 Author Share Posted April 15, 2009 Re-uploaded, zip file was corrupt Quote Link to comment Share on other sites More sharing options...
Guest Posted April 17, 2009 Share Posted April 17, 2009 Works wonderfully, thank you much!!! Quote Link to comment Share on other sites More sharing options...
Jonojamesmac Posted April 18, 2009 Author Share Posted April 18, 2009 V1.1 Uploaded - Changes below. - It is now possible to view credit card info if a customer has paid via your credit card input facilities. Note: Credit card info entered on your website is only included, 3rd Party credit card processors are not included. - Customer contact list has been added, similar to the layout of the iPhone/iPod Touch Contacts Application - Customers can now be contacted by SMS - Viewing a customer from the contact list will display all orders the customer has made. - Top Toolbar has navigation buttons for the new content. - Optional Model No has been added to the orders page, this may help if you catalogue your products via Model Number. - Reports Tool has been added, it is now possible to view the status of Products, Customers, Orders and the total amount in sales over current month, last month, current year and last year - Updated instructions to use SSL when using this App.(thanks Dave) - Index page is now index.php and not iphone.php This contribution has been uploaded as a completely new one, due to putting into wrong section. Awaiting to be manually added. Quote Link to comment Share on other sites More sharing options...
Jonojamesmac Posted April 18, 2009 Author Share Posted April 18, 2009 Contribution is now live. http://addons.oscommerce.com/info/6695 Updated two files and included in zip file. Quote Link to comment Share on other sites More sharing options...
Guest Posted April 19, 2009 Share Posted April 19, 2009 So, how do you keep anyone from navigating to this area on your server and viewing all of this info? What are all of the extra graphics for...in the images folder? Quote Link to comment Share on other sites More sharing options...
Jonojamesmac Posted April 19, 2009 Author Share Posted April 19, 2009 So, how do you keep anyone from navigating to this area on your server and viewing all of this info? What are all of the extra graphics for...in the images folder? The extra images came along with the iWebkit part of the app, they may come of use in the future. Protecting the area on your server is done by protecting the directory the contribution is in. The good thing about this contrib is that it doesn't have to be included in your shop directory, it can be placed anywhere on your server, and it can be accessed by a browser. If only you know the url then all is cool, but i understand that a username and password may be needed to protect it even more. The best method to protect the directory is via .htaccess for more information on that, click here Quote Link to comment Share on other sites More sharing options...
Guest Posted April 19, 2009 Share Posted April 19, 2009 The extra images came along with the iWebkit part of the app, they may come of use in the future. Protecting the area on your server is done by protecting the directory the contribution is in. The good thing about this contrib is that it doesn't have to be included in your shop directory, it can be placed anywhere on your server, and it can be accessed by a browser. If only you know the url then all is cool, but i understand that a username and password may be needed to protect it even more. The best method to protect the directory is via .htaccess for more information on that, click here I knew that you could move the app around on the server but that is still a very primitive type of protection when you start talking about credit card numbers, addresses, phone numbers, names, etc. I thought about the .htaccess but I wasn't sure how well it would work in conjunction with the iPhone. I currently don't have an iPhone so I couldn't test it. I was just trying to get the app ready for when I do get one. Quote Link to comment Share on other sites More sharing options...
Jonojamesmac Posted April 19, 2009 Author Share Posted April 19, 2009 I've just implemented it onto my version on the iPod Touch, i also have acces to an iPhone and .htacces protection requires you to enter a username and password everytime you open the app. Once the username and password is entered, you don't need to re-enter until the app is opened again. You could you a cookie-based protection with that, saving the password for so many days.. Quote Link to comment Share on other sites More sharing options...
Jonojamesmac Posted April 21, 2009 Author Share Posted April 21, 2009 (edited) Update uploaded - v1.2 - Added login/logout functionality, log in with your admin username/password. - Remember me option - All customers orders will always appear on customers page. - Credit Card info moved to order page. - Optional CVC added - Removed images that were not needed. Please note: Remember Me option only works with the iPhone, iPod Touch cookies are currently broken. Edited April 21, 2009 by Jonojamesmac Quote Link to comment Share on other sites More sharing options...
Guest Posted April 21, 2009 Share Posted April 21, 2009 Hi, I'm receiving an invalid username error. Any suggestions? Thanks, Adam Quote Link to comment Share on other sites More sharing options...
Jonojamesmac Posted April 21, 2009 Author Share Posted April 21, 2009 Your username may all be lowercase, the iPhone automatically makes the 1st character uppercase when typing it in Quote Link to comment Share on other sites More sharing options...
Guest Posted April 21, 2009 Share Posted April 21, 2009 I'm actually testing using my broswer at the moment. Its being typed in all lowercase as it is supposed to be? Quote Link to comment Share on other sites More sharing options...
Jonojamesmac Posted April 21, 2009 Author Share Posted April 21, 2009 (edited) I'm actually testing using my broswer at the moment. Its being typed in all lowercase as it is supposed to be? What browser are you using? Safari will display as if its on the iPhone, try that and you have configured the config.php yes? Edited April 21, 2009 by Jonojamesmac Quote Link to comment Share on other sites More sharing options...
Guest Posted April 21, 2009 Share Posted April 21, 2009 Using Safari. I did configure the config.php . I don't use a prefix for my databases. Could that be an issue? Quote Link to comment Share on other sites More sharing options...
Jonojamesmac Posted April 21, 2009 Author Share Posted April 21, 2009 I don't use prefixes either :) Copy/Paste this code into notepad and save it as code.php, upload it and run it. Let me know the outcome. <? include('config.php'); include('dbcon.php'); function checkColumn($columnname, $tablename) { $columns = array(); $table = $tablename; $query = 'SHOW COLUMNS FROM '.$table.';'; if ($results = mysql_query($query)) { if (mysql_num_rows($results) > 0) { while($row = mysql_fetch_row($results)) { $columns[] = $row[0]; } } } if (in_array($columnname, $columns)) { return 1; } else { return 0; } } $user = 'user_name'; $admintable = 'administrators'; $test = checkColumn($user, $admintable); if ($test == 1) { echo'OK - Admin Table Exists'; } else { echo'Not OK - Can\'t find the admin table'; } ?> Quote Link to comment Share on other sites More sharing options...
Guest Posted April 21, 2009 Share Posted April 21, 2009 Its not finding the admin table. Quote Link to comment Share on other sites More sharing options...
Jonojamesmac Posted April 21, 2009 Author Share Posted April 21, 2009 What is the name of the administrators table in your database? Quote Link to comment Share on other sites More sharing options...
Guest Posted April 21, 2009 Share Posted April 21, 2009 What is the name of the administrators table in your database? admin and here are the individual fields admin_id admin_groups_id admin_firstname admin_lastname admin_email_address admin_password admin_created admin_modified admin_logdate admin_lognum Quote Link to comment Share on other sites More sharing options...
Jonojamesmac Posted April 21, 2009 Author Share Posted April 21, 2009 Ok edit login.php replace on line 35: $q = "select user_password from administrators where user_name = '$username'"; with $q = "select admin_password from admin where user_name = '$username'"; and line 43 replace $stack = explode(':', $dbarray['user_password']); with $stack = explode(':', $dbarray['admin_password']); Quote Link to comment Share on other sites More sharing options...
Guest Posted April 21, 2009 Share Posted April 21, 2009 Thanks. This was my first guess but I was having difficulty finding which changes needed to be made. Quote Link to comment Share on other sites More sharing options...
Jonojamesmac Posted April 21, 2009 Author Share Posted April 21, 2009 Replace where user_name too with whatever you use to log in with, aka admin_firstname ? Quote Link to comment Share on other sites More sharing options...
Guest Posted April 21, 2009 Share Posted April 21, 2009 Hi, Loving this app! I've already made a ton of changes and updates (my oscommerce install is HIGHLY modified.) Could you possibly add a way to update the status? I think that this option would take this app to the next level as far as how useful it is. Quote Link to comment Share on other sites More sharing options...
Jonojamesmac Posted April 22, 2009 Author Share Posted April 22, 2009 (edited) Working on next update to include products information. I will work on the status update as well. Edited April 22, 2009 by Jonojamesmac Quote Link to comment Share on other sites More sharing options...
pbpools Posted April 27, 2009 Share Posted April 27, 2009 I get to the login page but keep getting Invalid Username? I know the password is correct because I set it up just for the iphone app? Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.