This topic is locked

is this possible?

1/6/2007 11:18:32 AM
PHPRunner General questions
P
ploppy author

hello. i downloaded the trial version (build 1.94) and like the program very much. however, before i decide to purchase or remove, i need to ask advice. What i am trying to do is to present a simple search front end to my customers. i cannot see any way to do this in the program. i have tried various options, but no luck. keeps appearing with all the results displayed. i do not want this. i only need to show results if they hit in the search option. Hope i made myself clear? Thanks. peter

L
larsonsc 1/6/2007

On the Edit SQL Query tab you can set the number of records shown on the first page. You could try setting that to 0 and see if that does what you need it to do. The other thing you can do if you use a menu is change the link to point to the ..._search.php page instead of _list.php. That would take them right to the search page where they can start their work.
Hope that helps you.

P
ploppy author 1/6/2007

thx 4 reply larson. i cannot seem to see a search.php file not even in the includes. what i have done is to set 0 show records on first page. hope that is ok? What i like about this prog is that is uses the smarty engine which offers flexible template system. Thank you for reply.

L
larsonsc 1/6/2007

If you have enabled advanced searching for the view you are working on there should be a file named with an _search.php in the root folder once the project has been built. For example if your view is named "My Records" your file would be named My_Records_search.php. You can edit the html for the menu to point to the search page, but I think showing 0 records probably acheives the same end result.
Take it easy! <img src='https://asprunner.com/forums/file.php?topicimage=1&fieldname=reply&id=14315&image=1&table=forumreplies' class='bbc_emoticon' alt=':)' />

P
ploppy author 1/6/2007

just one more thing. is it possible to import excel file? thanks for help.

L
larsonsc 1/6/2007

The are some programs that can do it, but PHPRunner isn't one of them. If you are using MySQL as your database software, EMS Software makes a product called Data Import for MySQL that seems to work fairly well provided your data in the spreadsheet is formatted the same way your database stores it.
I don't have any ties to EMS, so I'm not plugging anything that gets me anything. I'm just mentioning it because I've tested it against some spreadsheet imports myself.

P
ploppy author 1/6/2007

cheers larson. will check it out. does this prog clear itself of all previous entries once it is overwritten. i ask because, i amended a database and it is erroring still asking for the old table which i changed and uploaded to server via ftp. PHP error 256 'search/include/dbconnection.php' how do i clear this? thanks. peter

T
thesofa 1/6/2007

if you want to import data from an excel file to MYSQL, you could download the trial version of Navicat, or buy a licence for it, this allows total control of MYSQL databases, both locally, on a network and over the Internet. See the article here.

EMS SQL manager do a free trial from here but I have not tried it.

Excel MySQL Import, Export & Convert 1.3, has a free trial here.

Or you could just try this link in google here.

HTH

L
larsonsc 1/6/2007

cheers larson. will check it out. does this prog clear itself of all previous entries once it is overwritten. i ask because, i amended a database and it is erroring still asking for the old table which i changed and uploaded to server via ftp. PHP error 256 'search/include/dbconnection.php' how do i clear this? thanks. peter


To be perfectly honest, I'm not sure how the program behaves with data structure changes. I usually do my changes to my database (such as adding/removing tables, updating data types, etc) through phpMyAdmin direct on my webserver. I have found that by doing them that way, PHPRunner synchs pretty well with table changes. I'm not sure if you have that kind of access to your server though, so that may not work for you.

P
ploppy author 1/7/2007

thanks guys for the input. after using this program for a little while, i have com to the conclusion that it's main strengh is as an easy to use interface to create an administer databases through a GUI on a web server. As a backend tool, i think it is ace. However, it leaves me confused as to what it's functions are as a frontend customer search tool. In it's ad blurb, it states that visitors can add, edit,delete or update the database. why would your visitors want to do that? I can see this workign really well on an intranet or for a company where the emploee's would use it say on a helpdesk. If i am wrong guys, then acept my apologies and set me straight. as a further example, why when a visitor presses the search button with no input does it return all the resluts of the database? All the best guys and thanks for help so far. Peter

T
thesofa 1/7/2007

thanks guys for the input. after using this program for a little while, i have com to the conclusion that it's main strengh is as an easy to use interface to create an administer databases through a GUI on a web server. As a backend tool, i think it is ace. However, it leaves me confused as to what it's functions are as a frontend customer search tool. In it's ad blurb, it states that visitors can add, edit,delete or update the database. why would your visitors want to do that? I can see this workign really well on an intranet or for a company where the emploee's would use it say on a helpdesk. If i am wrong guys, then acept my apologies and set me straight. as a further example, why when a visitor presses the search button with no input does it return all the resluts of the database? All the best guys and thanks for help so far. Peter



This program is designed as a way of creating web pages to allow users to access the data held in a database.

A database manager who allowed users to access the database directly, either through the table and view management bits of PHPR or through another interface to a MYSQL datrabase, will not keep his/her job long.

IMHO it is not designed to create databases and tables on a database server, these functions are included for completeness, gretaer degerees of control are obtainable from otherr products mentioned in these fora, such as phpmyadmin, navicat, MYSQL Query Browser, etc.

Google will provide yopu with oodles of links to other front ends for managing MYSQL.

This programme, PHPR, is to save the web page designer from having to learn all the intricacies of writing queries in MYSQL also from all the pain involved in learning to write interactive web pages in PHP.

all of these are covered in PHPR.

The ads state > visitors can add, edit,delete or update the database.



This does not refer to the stucture of the database and its tables, but to the data.

Perhaps the ad needs to say that visitors to the web pages created by the programme can add, edit,delete or update the data held in the backend database through interactive web pages.

PHPR allows visitors to the web pages to form queries on the data held in the database through the search and advaced search functions that may be enabled on the web pages created by PHPR.

The .php pages created from the PHPR programme when you click 'build' are very comples, this allows complex queries on the data by anyone viewing the web pages without any knowledge of how it is done.

In addition, there is a very powerful security system, involving individual security about viewing data, in three stages, all can see and edit

all can see only owner can edit

only owner can see or edit.

In addition to that part, you can set up authentication in various ways

from data held in the code of the web pages

from data held in a table in the database

guest access

from data held in Active Directory, through hand made code mods using LDAP authentication against an LDAP server

In addition to this, you can set up UserGroups, and allow access to pages depending on the user group of the user who has logged in.

My main database for detention management in school, has 5 levels of user, Teacher, Form Tutor, Head of Department, Head of Year and Senior management.

this allows me to permit any or all of the data funstions to staff according to their user level.

In addition to all that, you can specify one use as a data manager who has access to everyone's date with all permissions granted.

As for your last point about a visiror searching with no input, think of a search as a filter, or a sieve.

If I specify search for users called thesofa, all the records are dropped into a sieve and only those that are not thesofa are dropped through

If I search for nothing, none of the records drop through, because they all have fields that are not nothing.
HTH

P
ploppy author 1/7/2007

thanks thesofa for a very informative explanation to my comments. On your last point however,

If I search for nothing, none of the records drop through, because they all have fields that are not nothing


is not happening in my case. if i press the submit button with no data input it returns all results in the database. Now if this is not supposed to happen, then i have coded something incorrectly. although whilst testing, i have accepted the defaults just to get to grips with the program. Thanks. peter

admin 1/7/2007

Search button acts as "Show all" if nothing is entered in the search box.

This is just an additional way to display all data in the table.
You can modify this in Visual Editor - just check if search box is empty and don't submit search form.

P
ploppy author 1/7/2007

thanks admin. just 2 more questions.

  1. based on your software uses smarty templates, can this be incorparated into x-cart?
  2. The following code to write names to the database in proper case:
    $str = $values["UserName"];

    for ($i=0; $i<strlen($str); $i++){

    if ($i==0) {

    $b = True;

    }

    else

    $b = (substr($str, $i-1,1) == " ");

    if ($<img src='https://asprunner.com/forums/file.php?topicimage=1&fieldname=reply&id=14375&image=1&table=forumreplies' class='bbc_emoticon' alt='B)' />

    $str = substr($str,0,$i).strtoupper(substr($str, $i,1)).substr($str, $i+1);

    }

    $values["UserName"] = $str;


Does this just apply to the first field ie, i have database wihich has first & last name. Can this be modified to cover both these fields.
Thank you for help.

admin 1/7/2007

I'm not familiar with x-cart to answer this question. Should be doable.
To aplly proper case code to two fields paste this code one more time and replace username with second field name.

P
ploppy author 1/7/2007

thank you very much. just FYO, x-cart is a smarty template driver e-commerce solution.

You can modify this in Visual Editor - just check if search box is empty and don't submit search form


where exactly do i modify this option. i cannot see this option in visual editor. do you have code to do this? Thank you.

admin 1/9/2007

If you are a registered user - send me your files and I'll help you with this.