[PHP] Re: PHP Framework

2005-11-15 Thread Aaron Greenspan

Yonatan,

And since I'm the Lampshade guy, I'll throw Lampshade out there, as well:

http://www.thinkcomputer.com/software/lampshade/index.html

Unlike a lot of frameworks, Lampshade is entirely procedural, and it's 
designed specifically for use with MySQL. I suppose that makes it less 
flexible than some people would want, but if it fits your application 
specs, then it's very fast and straightforward.


In general, it's been around since 2002 (no plans to go away next year), 
it's in use at Harvard and at very large companies, and at very small 
ones, too, and there's a whole lot of documentation, in both HTML and 
PDF format. I also happen to think that as far as programming frameworks 
go, it's pretty easy to learn. The Lampshade Starter Kit, which you can 
download alongside the core files, gives you an example application that 
you can work with and modify.


Good luck with your search!

Aaron

Aaron Greenspan
President  CEO
Think Computer Corporation

http://www.thinkcomputer.com

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP] Open Lampshade

2005-10-18 Thread Aaron Greenspan

Hi everyone,

Just thought you might like to know that Lampshade, our previously 
closed PHP framework, is now open-source:


http://www.thinkcomputer.com/corporate/news/pressreleases.html?id=24

Aaron

Aaron Greenspan
President  CEO
Think Computer Corporation

http://www.thinkcomputer.com

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP] Re: security/sql issues with php

2005-09-21 Thread Aaron Greenspan

Bruce,

If you're looking for commercial-grade open-source packages, I think 
you're going to have a pretty hard time finding much. Most 
commercial-grade software is...commercial. The truly robust open-source 
packages, i.e. Mozilla, MySQL, JBoss, BerkeleyDB, etc., are backed by 
some sort of commercial, or at the very least, corporate, entity. The 
rest, more often than not, are not commercial-grade; the support 
structures that companies require just don't exist for those packages.


I've offered to help you before via our commercial framework, Lampshade, 
which handles I'd say 98% of everything you want, and can be easily 
customized or added to in order to handle the remaining 2%. It's not 
open-source, but it also doesn't need to be since the documentation is 
so extensive. It's used in applications for all sorts of organizations 
from Harvard University to companies traded on the NYSE. There may be 
other open frameworks that are used just as widely--I would venture to 
guess phpNuke and the-CMS-formerly-known-as-Mambo--but as you've 
discovered, they don't do half of the things you'd like to see all in 
one place. Also, Mambo's political machinations are a good example of 
what you don't want to see in a commercial-grade product.


If you want to keep searching, I suppose no one's going to stop you. I'm 
just afraid it's not out there. Anyone, correct me if I'm wrong.


Best of luck,

Aaron

Aaron Greenspan
President  CEO
Think Computer Corporation

http://www.thinkcomputer.com

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP] Re: Modifying data in forms with values

2005-09-13 Thread Aaron Greenspan

Robert,

The Lampshade framework (and I'm sure others, too) handles pretty much 
all of the form controls for you. There' also a specific country() 
function used to make a drop-down of countries. Using Lampshade, you 
would only need one line of code in your form:


dropdownBox('country', country(), $myrow['country'], 'Country');

The first parameter is the name of the field in the form. The second 
provides the list of items to display in the drop-down box. The third is 
the present value of the box (so it handles the if statements you were 
talking about), and the fourth is the label that shows up on the form on 
the user's screen.


You should try it out, and I'd be happy to help you get set up.

http://www.thinkcomputer.com/software/lampshade/index.html

Aaron

Aaron Greenspan
President  CEO
Think Computer Corporation

http://www.thinkcomputer.com

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] Deny access from certain hosts

2005-09-13 Thread Aaron Greenspan

Jordan,

I have a similar problem where someone is using copyrighted images on my 
site in a bulletin board. It's not that one specific host is requesting 
the files--it's people from all over--but rather that I want to block 
one referring URL using Apache, rather than PHP, since the images are 
GIF files.


Can you do that with .htaccess?

Thanks,

Aaron

Aaron Greenspan
President  CEO
Think Computer Corporation

http://www.thinkcomputer.com

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP] Re: user registration/login - admin functions...

2005-09-07 Thread Aaron Greenspan

Bruce,

If your project isn't commercial in nature, you can use Lampshade for 
free...


http://www.thinkcomputer.com/software/lampshade/index.html

The Lampshade Starter Kit should already have a schema outlined for user 
and security management that you can integrate into your own application.


Aaron

Aaron Greenspan
President  CEO
Think Computer Corporation

http://www.thinkcomputer.com

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP] Re: Sort table by column and pagination

2005-08-26 Thread Aaron Greenspan

Daevid,

Lampshade, an API we've put together (as a commercially-backed 
alternative to PEAR) does table pagination and column sorting for you. 
It's free for non-commercial use, there's a lot of documentation, and 
I'm always around to answer questions:


http://www.thinkcomputer.com/software/lampshade/index.html

All you have to do is include the Lampshade files, set up a $table array 
in your page, and then call the table() function. You can integrate it 
with your current stylesheets, too.


Let me know if you have any other questions.

Aaron

Aaron Greenspan
President  CEO
Think Computer Corporation

http://www.thinkcomputer.com

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP] Re: Form Processor?

2005-08-16 Thread Aaron Greenspan

Hi,

Another shameless plug...

Lampshade makes form processing really easy. You define a $form array in 
your PHP file, you lay out the form in your form file, and go. It 
error-checks and submits for you. Non-commercial use is free, and 
there's an example application in the starter kit so you can see how it 
works.


http://www.thinkcomputer.com/software/lampshade

Or more specifically for forms...

http://www.thinkcomputer.com/software/lampshade/documentation.html?function=form

Aaron

Aaron Greenspan
President  CEO
Think Computer Corporation

http://www.thinkcomputer.com

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP] Re: Help Building Dynamic Checkboxes

2005-08-13 Thread Aaron Greenspan

Hi,

There are a couple of problems with your code. The first is that you 
have global variables enabled, which makes things easier, but also makes 
things less secure. You should definitely disable them in your php.ini 
file if possible.


Also, when you put the square brackets after gmev (gmev[]), you turn 
$_POST['gmev'] into an array. Yet your code just checks to see if the 
$_POST['gmev'] variable has any value at all, which of course, it does.



 if ($gmev) {
 $checked = ' checked=checked';
 } else {
 $checked = '';
 }

Therefore, when you go to present the form, $checked always has the 
string from the first case in the if statement, since you're not 
specifying which part of the $gmev array you really care about.


My suggestion to everyone dealing with these form problems, which are a 
general pain... Use Lampshade. It's so much easier! You can do this all 
in three lines of code: two to set up your choices for the form element, 
and one to draw the element itself.


http://www.thinkcomputer.com/software/lampshade

I'd be glad to help you with it if you have any questions.

Best of luck,

Aaron

Aaron Greenspan
President  CEO
Think Computer Corporation

http://www.thinkcomputer.com

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



Re: [PHP] Dropdown Building Function

2005-07-29 Thread Aaron Greenspan

Jay,

This is why I think frameworks are helpful Here's how I'd do it with 
Lampshade in one line of code with my own hypothetical field names:


dropdownBox('answerid', SELECT answerid, CONCAT(questions.description,' 
- ',answers.description) AS display FROM questions LEFT JOIN answers ON 
questions.questionid=answers.questionid ORDER BY questions.description, 
answers.description, $myrow['answerid'], 'Question and Answer', 'Choose 
an Answer');


For more information on this function:

http://www.thinkcomputer.com/software/lampshade/documentation.html?function=dropdownBox

I'd be happy to help you get it set up if you have any questions.

Aaron

Aaron Greenspan
President  CEO
Think Computer Corporation

http://www.thinkcomputer.com

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP] Re: application-wide shared data/object

2005-07-27 Thread Aaron Greenspan

Hi,

Not sure if everyone would agree, but I think the best way to go about 
doing this is just to make a table in a relational database. You can 
restrict access permissions using MySQL if that's something you're 
really concerned about, but there's basically no disadvantage to just 
storing your data in a MyISAM table instead of a shared object. You can 
index, sort, etc. very quickly that way. You can even load the result of 
the query into your $_SESSION variable after the first time so that you 
essentially have the result set cached. If indexing isn't a big deal, 
I'd just say store the data in a flat file. You can always move it 
outside of the web-accessible directory if you're worried about people 
accessing it directly.


Alternately, you could just store the data in a PHP file and include it 
in your scripts. Either way works, I think.


Aaron

Aaron Greenspan
President  CEO
Think Computer Corporation

http://www.thinkcomputer.com

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP] open_basedir Question

2005-07-26 Thread Aaron Greenspan

Hi,

Has anyone else had a problem with the open_basedir restriction 
completely ignoring what you tell it? I've added several directories to 
my allowed path (separated by colons) in my Apache configuration file, 
and then when I go to run my scripts, I'm told that 
/home/sites/site1/web/ and so on is not in my allowed path of 
/home/sites/site1. Trailing slashes don't change anything. A little weird...


This is on Linux with PHP 4.3.11. Several bugs on bugs.php.net from 2002 
reported similar behavior, but I don't think it's really been corrected. 
If this is a bug, it's a serious one from my perspective, because it 
means I turn off those restrictions entirely, which makes my entire 
server less secure.


Thanks,

Aaron

Aaron Greenspan
President  CEO
Think Computer Corporation

http://www.thinkcomputer.com

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP] Re: cannot connect to MySQL server and not sure why

2005-07-14 Thread Aaron Greenspan

Bruce,

Do you mean to have a space before the word password?

Aaron

Aaron Greenspan
President  CEO
Think Computer Corporation

http://www.thinkcomputer.com

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP] Re: Blocking login on the same username from diffrent computers

2005-07-13 Thread Aaron Greenspan

Yaron,

The Lampshade framework handles this for you. Any given user for an 
application can only log in from one place at a time; otherwise they'll 
be signed out from all of their other sessions.


If you're interested, take a look:

http://www.thinkcomputer.com/software/lampshade/free.html

Aaron

Aaron Greenspan
President  CEO
Think Computer Corporation

http://www.thinkcomputer.com

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP] Lampshade Download Site

2005-07-07 Thread Aaron Greenspan

Hello again,

Before I say anything else, Jaap and Casey, thanks for your feedback on 
our site design. I was laughing while I read it because I tend to agree 
with pretty much everything you mentioned. I don't know if I will sack 
the design staff, but I'll see what I can do.


Meanwhile, site design notwithstanding, you can visit:

http://www.thinkcomputer.com/software/lampshade/free.html

to download the free version of the Lampshade framework, version 1.0.2. 
We require you to tell us something about yourself, but that's basically 
it. Not a bad deal for normally expensive stuff that's being used all 
the way up to the Fortune 500. (Note: there's a catch--the e-commerce 
libraries aren't included in the free version, since profit 
automatically means commercial use, which you have to pay for.)


Aside from the obvious marketing value of doing this, my hope is that 
Lampshade will help prove that PHP is just as able as Java (and other 
languages) in a commercial environment, if not more so.


If you have any questions or comments, please feel free to e-mail.

Thanks,

Aaron

Aaron Greenspan
President  CEO
Think Computer Corporation

http://www.thinkcomputer.com

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php



[PHP] New Free PHP Framework: Lampshade

2005-07-01 Thread Aaron Greenspan

Hi everyone,

We've been charging for our PHP framework, Lampshade, for a long time, 
but we just decided to make it free for personal and academic use:


http://www.thinkcomputer.com/corporate/news/pressreleases.html?id=22

If you have any questions or would like a copy for yourself, let me know.

Thanks,

Aaron

Aaron Greenspan
President  CEO
Think Computer Corporation

http://www.thinkcomputer.com

--
PHP General Mailing List (http://www.php.net/)
To unsubscribe, visit: http://www.php.net/unsub.php