[web2py] TypeError: 'instancemethod' object is unsubscriptable

2012-05-06 Thread Annet
Using this code to customize a form:

div class=form
  div class=form-header
h3{{=response.functionname}}/h3
  /div !-- /form-header --
  div class=form-body
{{=form.custom.begin}}
{{=form.element['table']}}
  /div !-- /form-body --
  div class=form-footer
{{=DIV(form.custom.end[1])}}
{{=form.custom.end[0]}}
  /div !-- /form-footer --
/div !-- /form --

I get the following error:

Traceback (most recent call last):
  File /Library/Python/2.5/site-packages/web2py/gluon/restricted.py, line 
205, in restricted
exec ccode in environment
  File 
/Library/Python/2.5/site-packages/web2py/applications/bootstrap/views/util/generic.html,
 line 166, in module
TypeError: 'instancemethod' object is unsubscriptable


Line 166:

164. response.write(form.custom.begin)
165. response.write('\n', escape=False)
166. response.write(form.element['table'])


I am using web2py 1.99.7


Kind regards,

Annet.


[web2py] Re: Auth form custom errors

2012-05-06 Thread Rhys
Hey Massimo,

You've steered me in the right direction.

Basically I've had to put in a pure opening html form element in, and then 
use the custom form widgets afterwards. Works now. Resulting in:

form action=user/login method=post
{{=form.custom.widget.email}}
{{=form.custom.widget.password}}
{{=form.custom.end}}

The

form['_action'] = URL('user/login')

or

form.attributes['_action'] = URL('user/login')


for some reason didn't want to work. 

Cheers,

Rhys

On Sunday, May 6, 2012 3:50:52 PM UTC+10, Massimo Di Pierro wrote:

 This is because of the mechanism to prevent CSRF attacks.
 There are supposed to be two hidden fields, one is the formname. The other 
 is the formkey (a unique onetime token).

 Try:

 {{
 form=auth.login()
 form['_action']=URL('user/login')
 }}
 {{=form.custom.begin}}
 {{=form.custom.widget.email}}
 {{=form.custom.widget.password}}
 input type=submit value=login
 input type=hidden name=_next value=/feed
 {{=form.custom.end}}


 On Saturday, 5 May 2012 23:37:57 UTC-5, Rhys wrote:

 Hey Alan,

 I don't want to redirect. I'll try and to explain it a bit more.

 Basically I have two forms. One which is a drop down, in pure html

 form action=/user/login method=post
 input type=hidden name=_formname value=login
 input type=hidden name=_next value=/feed
input type=text name=email id=auth_user_email
 input type=password name=password id=aut_user_password
 input type=submit value=login
 /form



 ^ this Form is on every page which the user is not logged into. When they 
 fill out this form and click submit I want the /user/login page to process 
 it, but it is not doing so. When the page finds there is an error with the 
 login or the user is not authorised, I would like the /user/login form 
 which is exactly the same form as above but on another page with the drop 
 down one removed, to present there was an error with the login.

 Both forms I've done in html so there is no form key to process. I'm 
 trying to figure out why auth.login() doesn't process it as the 
 form.accepts() method in auth.login() has the same formname. What is 
 preventing it from being processed. It's driving me in sane. I'm stepping 
 through the code in debug mode and can't find why it would not process it. 
 It is basically a SQL form in html like described in the web2py book.

 Any insight would be great by any!

 On Sunday, May 6, 2012 12:19:49 AM UTC+10, Alan Etkin wrote:

 *auth.is_logged_in()* will return a bool object. True for authenticated 
 user and I belive *auth.user_id* attribute is None for the non 
 authenticated user. *auth *being the Auth class instance created by the 
 welcome scaffolding application.

 You could use the returned values to catch unsuccessful authentication 
 and redirect to the correct action

 There is an Auth setting for failed authentication (for example, it's 
 possible to call a function on failed login)
 (Settings and Messages, web2py book 4th edition, 9.3.7)

 auth.settings.on_failed_authentication = lambda url: redirect(url)

 On Saturday, May 5, 2012 9:51:23 AM UTC-3, Rhys wrote:

 I'm creating a custom drop down login form for all pages where the user 
 isn't logged in. Once they try and login through this form if it 
 is unsuccessful it redirects to the /user/login page with the auth.login 
 form. How do I get a error if the login has resulted in an invalid login. 
 As there are two forms I've tried also tried to do a form out of html so 
 there is no form key. Still no luck. Is it s simple variable I can use to 
 determine if it is successful? 



[web2py] localhost external machine.

2012-05-06 Thread Mchurch
Good morning to everybody.
I've a web2py application on a windows machine, the public windows ip 
machine is 192.168.100.191.
From my mobile cell (nor tablet..) i can't get localhost.
I tried many times with 0.0.0.0, 127.0.0.1, and even if with the public ip 
192.168.100.191 but i always get SITE DOWN FOR MAINTENANCE
If I access localhost form the windows machine everything works fine.
It seems to me some permission problem
Help please.
Many thanks.
Marco.


Re: [web2py] localhost external machine.

2012-05-06 Thread Bruno Rocha
python web2py.py -a yourpassword -i 0.0.0.0 -p 8000

if you are using windows version, just set the interface as 0.0.0.0 in the
web2py widget.

Or are you using some other webserver?

On Sun, May 6, 2012 at 5:49 AM, Mchurch mchurc...@gmail.com wrote:

 Good morning to everybody.
 I've a web2py application on a windows machine, the public windows ip
 machine is 192.168.100.191.
 From my mobile cell (nor tablet..) i can't get localhost.
 I tried many times with 0.0.0.0, 127.0.0.1, and even if with the public ip
 192.168.100.191 but i always get SITE DOWN FOR MAINTENANCE
 If I access localhost form the windows machine everything works fine.
 It seems to me some permission problem
 Help please.
 Many thanks.
 Marco.




-- 

Bruno Rocha
[http://rochacbruno.com.br]


[web2py] store formated text in a text field of a table

2012-05-06 Thread BlueShadow
Hi,
I got a table for Articles I want to write someday on my page which 
contains a text field for the content.
My Problem is that it does not allow me to store any format no newlines 
paragraphs bold stuff links or anything along this line. It just turns out 
to be plain text.
I tried html tags escape characters like \n
Is there perhaps even some code for an editor field like one is used to in 
most forums.
Thanks


Re: [web2py] store formated text in a text field of a table

2012-05-06 Thread Khalil KHAMLICHI
if content of field is in html try : {{=XML(row.field)}}

On Sun, May 6, 2012 at 9:48 AM, BlueShadow kevin.bet...@gmail.com wrote:

 Hi,
 I got a table for Articles I want to write someday on my page which
 contains a text field for the content.
 My Problem is that it does not allow me to store any format no newlines
 paragraphs bold stuff links or anything along this line. It just turns out
 to be plain text.
 I tried html tags escape characters like \n
 Is there perhaps even some code for an editor field like one is used to in
 most forums.
 Thanks



Re: [web2py] localhost external machine.

2012-05-06 Thread Ricardo Pedroso
On Sun, May 6, 2012 at 9:49 AM, Mchurch mchurc...@gmail.com wrote:
 Good morning to everybody.
 I've a web2py application on a windows machine, the public windows ip
 machine is 192.168.100.191.
 From my mobile cell (nor tablet..) i can't get localhost.
 I tried many times with 0.0.0.0, 127.0.0.1, and even if with the public ip
 192.168.100.191 but i always get SITE DOWN FOR MAINTENANCE
 If I access localhost form the windows machine everything works fine.
 It seems to me some permission problem

In gluon/main.py you have this piece of code:
elif not request.is_local and \
os.path.exists(os.path.join(request.folder,'DISABLED')):
raise HTTP(200, htmlbodyh1Down for
maintenance/h1/body/html)

Check if you have a DISABLED file in your app directory.

Ricardo


Re: [web2py] store formated text in a text field of a table

2012-05-06 Thread BlueShadow
OK that works but it is still a little inconvienient to write an html tag 
for every new line you want.
for links and stuff thats OK but a newline should work without a tag.

On Sunday, May 6, 2012 11:55:39 AM UTC+2, Khalil KHAMLICHI wrote:

 if content of field is in html try : {{=XML(row.field)}}

 Hi,
 I got a table for Articles I want to write someday on my page which 
 contains a text field for the content.
 My Problem is that it does not allow me to store any format no newlines 
 paragraphs bold stuff links or anything along this line. It just turns out 
 to be plain text.
 I tried html tags escape characters like \n
 Is there perhaps even some code for an editor field like one is used to 
 in most forums.
 Thanks




[web2py] Bootstrap.min.js

2012-05-06 Thread Aurelijus Useckas
Hi, 

The Bootstrap.min.js in the Trunk layout.html is included in the beginning 
HEAD section. This didn't allow me to make use of the most, if not all of 
Bootstrap functions which required .js. Moving the inclusion to the end of 
the file solved the problem. 


[web2py] Re: default/user.html and custom form

2012-05-06 Thread Cédric Mayer
The fact is that you know more about web2py and details than me :-)
I learned about form.custom after I had done my function and used it in my 
views. But even then I didn't know about the split form.custom.end[1]  to 
get hidden fields.
By the way I do not think it is in the book, you may add it. 
http://web2py.com/books/default/chapter/29/7#Custom-forms
Thank you for teaching us ;-)

Le samedi 5 mai 2012 15:30:22 UTC+2, Massimo Di Pierro a écrit :

 I do not understand the purpose of all this. Why not:


 {{=form.custom.begin}}
 {{#!-- Add header here --}}
 {{=form.element['table']}}
 {{#!-- Add footer here --}}
 {{=DIV(form.custom.end[1] # hidden field}}
 {{#!-- Add submit/cancel buttons here - you may even not use the submit 
 variable --}}
 {{=INPUT('extra button'}}
 {{=form.custom.end[0] # /form}}


 Notice there is also a form.add_button() in trunk.

 On Saturday, 5 May 2012 00:49:38 UTC-5, Cédric Mayer wrote:

 As I needed to build my own submit buttons, or add my own widgets, I use 
 the following function to split a SQLFORM:
 import re

 def expurgate_form(web2py_form):
 '''
 Deletes surrounding form tag, and submit row.
 '''
 regexp_opening_tag = re.compile(^[^]*)
 regexp_closing_tag = re.compile([^]*$)
 form_xml = web2py_form.xml()
 opening_tag = regexp_opening_tag.search(form_xml).group()
 closing_tag = regexp_closing_tag.search(form_xml).group()
 realform=TAG(form_xml)
 table = realform.elements('table')[0]
 hidden_elements = realform.elements(input[type=hidden])
 hidden_element = DIV(*hidden_elements)
 hidden_element['_style'] = display:none;
 todelete = table.elements(input[type=submit])
 submit = todelete[0]
 todelete[0].parent[0]=''
 return (table,hidden_element,XML(opening_tag),XML(closing_tag),submit
 )


 To use it in a view:
 {{(table,hidden_element,opening_tag,closing_tag,submit)=expurgate_form(
 form)}}
 {{=opening_tag}}
 {{#!-- Add header here --}}
 {{=table}}
 {{#!-- Add footer here --}}
  {{=hidden_element}}
 {{#!-- Add submit/cancel buttons here - you may even not use the submit 
 variable --}}
  {{=submit}}
  {{=closing_tag}}


 I hope it will help :-)


 Le vendredi 4 mai 2012 08:30:23 UTC+2, Annet a écrit :

 I'd like to divide the default/user.html forms into a body and footer 
 part, the body containing the fields the footer containing the cancel and 
 submit button, something like this:

 div class=form
   div class=form-header
 h3Login with your Leonexus ID/h3
   /div !-- /form-header --
   div class=form-body
   h5Enter your username and password/h5

   the form fields here

   /div !-- /form-body --
   div class=form-footer

   the form controls here

   /div !-- /form-footer --
  /div !-- /form --

 Is there a way to split the form in these components?


 Kind regards,

 Annet



[web2py] Re: LOAD with timing arguments being loaded once

2012-05-06 Thread Alan Etkin
Well, here's the thing:
The timing options *are* in the web2py.js file in hg trunk, inside 
applications/welcome, it's just that they are not updated in my local 
welcome.w2p file. So, if admin uses this .w2p file when creating a new app, 
I will have an outdated version of the scaffolding application (is this 
correct?). How should I fix this issue.

On Saturday, May 5, 2012 11:11:52 PM UTC-3, Massimo Di Pierro wrote:

 Please do.


 On Saturday, 5 May 2012 19:34:02 UTC-5, Alan Etkin wrote:

 I've found something on the subject. web2py.js function web2py_component 
 time and times arguments and the code related with js timing were not 
 included in the last version of the script. I think this should be fixed 
 for backwards compatibility (LOAD at compileapp.py builds web2py_component 
 commands with those arguments). Should I submit a patch for this?.

 On Saturday, May 5, 2012 8:23:26 PM UTC-3, Alan Etkin wrote:

 I am having trouble using the LOAD timing features i.e:

 LOAD(f=action.load, timeout=1000, times=infinity, ajax=True)

 The component is loaded just the first time and it should keep reloading 
 it on each second.

 I've tried the command with the last trunk hg version. Anyone with the 
 same issue?

 The system info:
 web2py Version 1.99.7 (2012-05-05 09:00:54) dev (with rocket web server)
 Browser: Firefox 10.0
 OS: Mandriva GNU/Linux 2010.2



[web2py] Re: Unable to restart Web2py on Mac

2012-05-06 Thread Yarin
This is still broken:

I'm running web2py with the built-in Rocket server locally on my Mac. When 
I click the stop server button on the server window, and then click 
start server to restart, I get the following:

ERROR:Rocket.Errors.Port8000:Socket 127.0.0.1:8000 in use by other process 
and it won't share.
please visit:
http://127.0.0.1:8000
starting browser...
WARNING:Rocket.Errors.Port8000:Listener started when not ready.

The only way I can get past that is to quit Python.

Is there a way to restart web2py from the command line without having to 
quit python each time?

On Thursday, February 17, 2011 4:10:21 PM UTC-5, pbreit wrote:

 Did anyone figure out how to stop and start Web2py from the console on a 
 Mac? When I do it, it doesn't work when it starts back up. It stalls when 
 it opens up the browser window and tries to go to my home page. I remember 
 some discussion about processes not shutting down quickly or at all. Is 
 there any solution?

 I end up having to quit and restart web2py.app every time.



[web2py] Re: TypeError: 'instancemethod' object is unsubscriptable

2012-05-06 Thread Massimo Di Pierro
 {{=form.element('table')}}

or

 {{=form[0]}}

On Sunday, 6 May 2012 01:20:51 UTC-5, Annet wrote:

 Using this code to customize a form:

 div class=form
   div class=form-header
 h3{{=response.functionname}}/h3
   /div !-- /form-header --
   div class=form-body
 {{=form.custom.begin}}
 {{=form.element['table']}}
   /div !-- /form-body --
   div class=form-footer
 {{=DIV(form.custom.end[1])}}
 {{=form.custom.end[0]}}
   /div !-- /form-footer --
 /div !-- /form --

 I get the following error:

 Traceback (most recent call last):
   File /Library/Python/2.5/site-packages/web2py/gluon/restricted.py, line 
 205, in restricted
 exec ccode in environment
   File 
 /Library/Python/2.5/site-packages/web2py/applications/bootstrap/views/util/generic.html,
  line 166, in module
 TypeError: 'instancemethod' object is unsubscriptable


 Line 166:

 164. response.write(form.custom.begin)
 165. response.write('\n', escape=False)
 166. response.write(form.element['table'])


 I am using web2py 1.99.7


 Kind regards,

 Annet.



[web2py] Re: Auth form custom errors

2012-05-06 Thread Massimo Di Pierro
Interesting. When you say it did not work. What html did it generate?

On Sunday, 6 May 2012 03:25:41 UTC-5, Rhys wrote:

 Hey Massimo,

 You've steered me in the right direction.

 Basically I've had to put in a pure opening html form element in, and then 
 use the custom form widgets afterwards. Works now. Resulting in:

 form action=user/login method=post
 {{=form.custom.widget.email}}
 {{=form.custom.widget.password}}
 {{=form.custom.end}}

 The

 form['_action'] = URL('user/login')

 or

 form.attributes['_action'] = URL('user/login')


 for some reason didn't want to work. 

 Cheers,

 Rhys

 On Sunday, May 6, 2012 3:50:52 PM UTC+10, Massimo Di Pierro wrote:

 This is because of the mechanism to prevent CSRF attacks.
 There are supposed to be two hidden fields, one is the formname. The 
 other is the formkey (a unique onetime token).

 Try:

 {{
 form=auth.login()
 form['_action']=URL('user/login')
 }}
 {{=form.custom.begin}}
 {{=form.custom.widget.email}}
 {{=form.custom.widget.password}}
 input type=submit value=login
 input type=hidden name=_next value=/feed
 {{=form.custom.end}}


 On Saturday, 5 May 2012 23:37:57 UTC-5, Rhys wrote:

 Hey Alan,

 I don't want to redirect. I'll try and to explain it a bit more.

 Basically I have two forms. One which is a drop down, in pure html

 form action=/user/login method=post
 input type=hidden name=_formname value=login
 input type=hidden name=_next value=/feed
input type=text name=email id=auth_user_email
 input type=password name=password id=aut_user_password
 input type=submit value=login
 /form



 ^ this Form is on every page which the user is not logged into. When 
 they fill out this form and click submit I want the /user/login page to 
 process it, but it is not doing so. When the page finds there is an error 
 with the login or the user is not authorised, I would like the /user/login 
 form which is exactly the same form as above but on another page with the 
 drop down one removed, to present there was an error with the login.

 Both forms I've done in html so there is no form key to process. I'm 
 trying to figure out why auth.login() doesn't process it as the 
 form.accepts() method in auth.login() has the same formname. What is 
 preventing it from being processed. It's driving me in sane. I'm stepping 
 through the code in debug mode and can't find why it would not process it. 
 It is basically a SQL form in html like described in the web2py book.

 Any insight would be great by any!

 On Sunday, May 6, 2012 12:19:49 AM UTC+10, Alan Etkin wrote:

 *auth.is_logged_in()* will return a bool object. True for 
 authenticated user and I belive *auth.user_id* attribute is None for 
 the non authenticated user. *auth *being the Auth class instance 
 created by the welcome scaffolding application.

 You could use the returned values to catch unsuccessful authentication 
 and redirect to the correct action

 There is an Auth setting for failed authentication (for example, it's 
 possible to call a function on failed login)
 (Settings and Messages, web2py book 4th edition, 9.3.7)

 auth.settings.on_failed_authentication = lambda url: redirect(url)

 On Saturday, May 5, 2012 9:51:23 AM UTC-3, Rhys wrote:

 I'm creating a custom drop down login form for all pages where the 
 user isn't logged in. Once they try and login through this form if it 
 is unsuccessful it redirects to the /user/login page with the auth.login 
 form. How do I get a error if the login has resulted in an invalid login. 
 As there are two forms I've tried also tried to do a form out of html so 
 there is no form key. Still no luck. Is it s simple variable I can use to 
 determine if it is successful? 



[web2py] Re: Bootstrap.min.js

2012-05-06 Thread Massimo Di Pierro
Is that how it is intended to be used? Can you point me to an example in 
the docs?

On Sunday, 6 May 2012 06:05:58 UTC-5, Aurelijus Useckas wrote:

 Hi, 

 The Bootstrap.min.js in the Trunk layout.html is included in the beginning 
 HEAD section. This didn't allow me to make use of the most, if not all of 
 Bootstrap functions which required .js. Moving the inclusion to the end of 
 the file solved the problem. 



[web2py] Re: LOAD with timing arguments being loaded once

2012-05-06 Thread Massimo Di Pierro
When you install web2py from the zip, there is a file called 
web2py/NEWINSTALL. When this file is found (even if empty), web2py rebuilds 
welcome.w2p.

On Sunday, 6 May 2012 09:02:36 UTC-5, Alan Etkin wrote:

 Well, here's the thing:
 The timing options *are* in the web2py.js file in hg trunk, inside 
 applications/welcome, it's just that they are not updated in my local 
 welcome.w2p file. So, if admin uses this .w2p file when creating a new app, 
 I will have an outdated version of the scaffolding application (is this 
 correct?). How should I fix this issue.

 On Saturday, May 5, 2012 11:11:52 PM UTC-3, Massimo Di Pierro wrote:

 Please do.


 On Saturday, 5 May 2012 19:34:02 UTC-5, Alan Etkin wrote:

 I've found something on the subject. web2py.js function web2py_component 
 time and times arguments and the code related with js timing were not 
 included in the last version of the script. I think this should be fixed 
 for backwards compatibility (LOAD at compileapp.py builds web2py_component 
 commands with those arguments). Should I submit a patch for this?.

 On Saturday, May 5, 2012 8:23:26 PM UTC-3, Alan Etkin wrote:

 I am having trouble using the LOAD timing features i.e:

 LOAD(f=action.load, timeout=1000, times=infinity, ajax=True)

 The component is loaded just the first time and it should keep 
 reloading it on each second.

 I've tried the command with the last trunk hg version. Anyone with the 
 same issue?

 The system info:
 web2py Version 1.99.7 (2012-05-05 09:00:54) dev (with rocket web server)
 Browser: Firefox 10.0
 OS: Mandriva GNU/Linux 2010.2



[web2py] Another misinformed article about web2py

2012-05-06 Thread Massimo Di Pierro
http://me.veekun.com/blog/2012/05/05/python-faq-webdev/


[web2py] response not displaying correctly in iframe

2012-05-06 Thread simon
Please can someone explain this.

When I enter test using the code below then I can see a page with TEST 
and  CONTENTS which is what I wanted.
However when I open test/4 it shows three nested iframes  each with TEST

def test():
response.view=default/test.html
return dict()
def webpage():
return XML(CONTENTS)

test.html

TEST
iframe src='webpage.html' scrolling=no width=100%/iframe


[web2py] Re: store formated text in a text field of a table

2012-05-06 Thread simon
http://www.web2pyslices.com/slice/show/1345/using-ckeditor-for-text-fields 

On Sunday, 6 May 2012 10:48:12 UTC+1, BlueShadow wrote:

 Hi,
 I got a table for Articles I want to write someday on my page which 
 contains a text field for the content.
 My Problem is that it does not allow me to store any format no newlines 
 paragraphs bold stuff links or anything along this line. It just turns out 
 to be plain text.
 I tried html tags escape characters like \n
 Is there perhaps even some code for an editor field like one is used to in 
 most forums.
 Thanks



[web2py] Re: Another misinformed article about web2py

2012-05-06 Thread Gour
On Sun, 6 May 2012 08:11:07 -0700 (PDT)
Massimo Di Pierro
massimo.dipie...@gmail.com wrote:

 http://me.veekun.com/blog/2012/05/05/python-faq-webdev/

The post which says Allegedly...so don’t use it if you care... 
spekas for itself.

I just wonder why writing about things one does not have a clue.


Sincerely,
Gour

-- 
The intricacies of action are very hard to understand. 
Therefore one should know properly what action is, 
what forbidden action is, and what inaction is.

http://atmarama.net | Hlapicina (Croatia) | GPG: 52B5C810


signature.asc
Description: PGP signature


[web2py] Re: Bootstrap.min.js

2012-05-06 Thread Aurelijus Useckas
I'm not sure if it is intended that way, haven't read about it in the docs. 
It's just the only solution that has worked for me. 

On Sunday, May 6, 2012 5:53:57 PM UTC+3, Massimo Di Pierro wrote:

 Is that how it is intended to be used? Can you point me to an example in 
 the docs?

 On Sunday, 6 May 2012 06:05:58 UTC-5, Aurelijus Useckas wrote:

 Hi, 

 The Bootstrap.min.js in the Trunk layout.html is included in the 
 beginning HEAD section. This didn't allow me to make use of the most, if 
 not all of Bootstrap functions which required .js. Moving the inclusion to 
 the end of the file solved the problem. 



[web2py] Re: Admin interface slow when static dir has a lot of files

2012-05-06 Thread Larry Weinberg
Is this being addressed?  I am finding the same problem.  Other than that, 
and a couple of other suggestions for having more links to speed up the 
admin interface workflow I am loving web2py!

[web2py] Candidate Employment Tracking Portal

2012-05-06 Thread Yogesh Kamat
Just checked out some videos of pycon2012 by Massimo  and in 30 mins flat, 
i was really impressed. With really efforts that has been possible.. since 
i have read the hardships faced for entering pycon2011.

I have been searching resources for developing a few applications which 
have been greatly unanswered by the programming community at a large..

I want to develop a Candidate Employment application tracker. wherein a 
Prospective candidate enters his/her details and the same can be checked by 
the prospective employer and can rate the applications accordingly. It 
would not be a job employment portal but rather just an internal tracker.

We tried working on Zend PHP since we have a programmer who know php, it is 
taking too much time frankly to say and with no great database experience.
*Now with our programmer out i have decided to write it on web2py, i have 
just an experience on HTML CSS, jquery kind of coding.. *

Web2py would be useful i understand since sql is written by web2py engine 
itself.

We had originally planned for a *multi step form wizard* kind of stuff to 
get registration.
Then a admin logins to manage and screen this applications.

I need guidance to start on this project. I have bought the web2py cookbook 
too... which gives me an overview to start.



[web2py] query referenced table in grid/smartgrid

2012-05-06 Thread Mathias

Is there an easy way to query a referenced table in a grid/smartgrid ?

Is the only way, to achieve this goal, writing a search_widget ?

Does anyone already has written some code to achieve this goal ?

Thanks

Mathias


Re: [web2py] Re: localhost external machine.

2012-05-06 Thread Yogesh
Hello Marco,
192.168.x.x is a private network IP. Not able to check out..

Regards,
Yogesh

On Sun, May 6, 2012 at 9:39 PM, Mchurch mchurc...@gmail.com wrote:

 ThankYou guys.
 The file was enabled, but doing some more trying i was able to get
 localhost using public ip 192.168.100.191 (I'm catching all connections
 with a hotspot and redirecting users to
 http://192.168.100.191:8000/restaurant/default/show
 Now, on my Mac, doing that, i can see every pictures from my mobile.
 With windows i can't see images!! I tried with tornado and rocket, but
 same result.
 I think i'm loosing some path and jquery is getting crazy; may be i must
 use some absolute path  in this view?
 The server is doing its job, and the logic too, server side is ok, it
 should be some javascript path

 !DOCTYPE html
 html lang=en
 head
 titleResponsive Image Gallery/title
 meta charset=UTF-8 /
 meta http-equiv=X-UA-Compatible content=IE=edge,chrome=1
 meta name=viewport content=width=device-width,
 initial-scale=1.0, maximum-scale=1.0, user-scalable=no
 meta name=description content=Responsive Image Gallery with
 jQuery /
 meta name=keywords content=jquery, carousel, image gallery,
 slider, responsive, flexible, fluid, resize, css3 /
 meta name=author content=Codrops /
 link rel=shortcut icon href=../favicon.ico
 link rel=stylesheet type=text/css href=
 /{{=request.application}}/static/css/demo.css /
 link rel=stylesheet type=text/css href=
 /{{=request.application}}/static/css/style.css /
 link rel=stylesheet type=text/css href=
 /{{=request.application}}/static/css/elastislide.css /
 link href='
 http://fonts.googleapis.com/css?family=PT+Sans+Narrowv1' rel='stylesheet'
 type='text/css' /
 link href='http://fonts.googleapis.com/css?family=Pacifico' rel=
 'stylesheet' type='text/css' /
 script type=text/javascript src=
 http://ajax.googleapis.com/ajax/libs/jquery/1.6.4/jquery.min.js;/script
 noscript
 style
 .es-carousel ul{
 display:block;
 }
 /style
 /noscript
 script
 $(function() {
  var pgurl = window.location.href.substr(window.location.href.
 lastIndexOf(/)+1);
 $(#nav li a).each(function(){
 controllo=$(this).attr(href).substr($(this).attr(href).
 lastIndexOf(/)+1);

   if(controllo == pgurl)
   $(this).addClass(selected);
  })
 });
 /script
 script id=img-wrapper-tmpl type=text/x-jquery-tmpl
 div class=rg-image-wrapper


 div class=rg-image-nav
 a href=# class=rg-image-nav-prevPrevious
 Image/a
 a href=# class=rg-image-nav-nextNext Image/
 a
 /div


 div class=rg-image/div
 div class=rg-loading/div
 div class=rg-caption-wrapper
 div class=rg-caption style=display:none;
 p/p
 /div
 /div
 /div
 /script
 /head
 body
 I CAN SEE THISimg src=
 /{{=request.application}}/static/images/bandiera_italiana.png
 div class=container
 div class=headerdiv class=clr/div/div!-- header
 --
 div class=content
 div class=rg-image-wrapperdiv class=rg-image-nav/div
 div class=rg-imageimg src=
 /{{=request.application}}/static/images/header-2.jpg/div
 div class=rg-loading style=display: none; /div
 div class=rg-caption-wrapperdiv class=rg-caption style=
 /div/div
  /div

 div id=rg-gallery class=rg-gallery
 div class=rg-thumbs
 !-- Elastislide Carousel Thumbnail Viewer --
 div id=pippo class=
 es-carousel-wrapperbandiere
 div class=es-nav
 span class=es-nav-prevPrevious/span
 span class=es-nav-nextNext/span
 /div
 div class=es-carouselbandiere
 ul{{ for elemento in ciclo:}}
 li

 {{immagine=IMG(_src=/+request.application+ /static/images/ +
 elemento.bandiera)}}
 {{=A(immagine, _href=URL('show',
 vars=dict(lingua=elemento.id,bandiera=elemento.bandiera)))}}
 /li
 {{pass}}
 /ul
 /div
  /div
 !-- End Elastislide Carousel Thumbnail Viewer --
 /div!-- rg-thumbs --
 spanh1Benvenuti al Ristorante Italia/h1 /span
 {{include 'default/menu.html'}}

 div class=rg-thumbs
 !-- Elastislide Carousel Thumbnail Viewer --

[web2py] Re: LOAD with timing arguments being loaded once

2012-05-06 Thread Alan Etkin
Thanks very much Massimo. I've placed the empty file missing in my local 
copy of the hg repository. That solved it

On Sunday, May 6, 2012 11:55:44 AM UTC-3, Massimo Di Pierro wrote:

 When you install web2py from the zip, there is a file called 
 web2py/NEWINSTALL. When this file is found (even if empty), web2py rebuilds 
 welcome.w2p.

 On Sunday, 6 May 2012 09:02:36 UTC-5, Alan Etkin wrote:

 Well, here's the thing:
 The timing options *are* in the web2py.js file in hg trunk, inside 
 applications/welcome, it's just that they are not updated in my local 
 welcome.w2p file. So, if admin uses this .w2p file when creating a new app, 
 I will have an outdated version of the scaffolding application (is this 
 correct?). How should I fix this issue.

 On Saturday, May 5, 2012 11:11:52 PM UTC-3, Massimo Di Pierro wrote:

 Please do.


 On Saturday, 5 May 2012 19:34:02 UTC-5, Alan Etkin wrote:

 I've found something on the subject. web2py.js function 
 web2py_component time and times arguments and the code related with js 
 timing were not included in the last version of the script. I think this 
 should be fixed for backwards compatibility (LOAD at compileapp.py builds 
 web2py_component commands with those arguments). Should I submit a patch 
 for this?.

 On Saturday, May 5, 2012 8:23:26 PM UTC-3, Alan Etkin wrote:

 I am having trouble using the LOAD timing features i.e:

 LOAD(f=action.load, timeout=1000, times=infinity, ajax=True)

 The component is loaded just the first time and it should keep 
 reloading it on each second.

 I've tried the command with the last trunk hg version. Anyone with the 
 same issue?

 The system info:
 web2py Version 1.99.7 (2012-05-05 09:00:54) dev (with rocket web 
 server)
 Browser: Firefox 10.0
 OS: Mandriva GNU/Linux 2010.2



Re: [web2py] Re: Another misinformed article about web2py

2012-05-06 Thread Yogesh
*Friends, *

I have put my comments out there.
Years back i had read comments against silverstripe, but therein the person
had mentioned what's wrong in the coding and approach taken by
silverstripe. and the guys replied positively to the comment and fixed
where required.
Check out for your reference:
http://seancoates.com/blogs/why-i-wont-recommend-silverstripe

In the case below,  I agree there should have been a mention where the
problem is rather than a loose vague comment.

Thanks,
*Yogesh*

On Sun, May 6, 2012 at 9:31 PM, Gour g...@atmarama.net wrote:

 On Sun, 6 May 2012 08:11:07 -0700 (PDT)
 Massimo Di Pierro
 massimo.dipie...@gmail.com wrote:

  http://me.veekun.com/blog/2012/05/05/python-faq-webdev/

 The post which says Allegedly...so don’t use it if you care...
 spekas for itself.

 I just wonder why writing about things one does not have a clue.


 Sincerely,
 Gour

 --
 The intricacies of action are very hard to understand.
 Therefore one should know properly what action is,
 what forbidden action is, and what inaction is.

 http://atmarama.net | Hlapicina (Croatia) | GPG: 52B5C810



[web2py] Re: Admin interface slow when static dir has a lot of files

2012-05-06 Thread Massimo Di Pierro
You should not let rocket serve static files. I would use a production 
quality server luke apache or ngnix.
Anyway, it is not a good idea to have too many files in the same folder. 
Just accessing the file system becomes a bottle neck.
One way to increase efficiency is to move the static files to the 
app-ending or github and link those.

On Sunday, 6 May 2012 10:33:00 UTC-5, Larry Weinberg wrote:

 Is this being addressed?  I am finding the same problem.  Other than that, 
 and a couple of other suggestions for having more links to speed up the 
 admin interface workflow I am loving web2py!



[web2py] Re: response not displaying correctly in iframe

2012-05-06 Thread Massimo Di Pierro
That;s how html understand paths. Do it the safe web2py way:

iframe src='{{=URL('webpage.html')}}' scrolling=no width=100%/iframe

On Sunday, 6 May 2012 10:33:58 UTC-5, simon wrote:

 Please can someone explain this.

 When I enter test using the code below then I can see a page with TEST 
 and  CONTENTS which is what I wanted.
 However when I open test/4 it shows three nested iframes  each with TEST

 def test():
 response.view=default/test.html
 return dict()
 def webpage():
 return XML(CONTENTS)

 test.html

 TEST
 iframe src='webpage.html' scrolling=no width=100%/iframe



[web2py] Re: Bootstrap.min.js

2012-05-06 Thread Massimo Di Pierro
Can you please post example of what you did an more explanations about why?

On Sunday, 6 May 2012 11:20:39 UTC-5, Aurelijus Useckas wrote:

 I'm not sure if it is intended that way, haven't read about it in the 
 docs. It's just the only solution that has worked for me. 

 On Sunday, May 6, 2012 5:53:57 PM UTC+3, Massimo Di Pierro wrote:

 Is that how it is intended to be used? Can you point me to an example in 
 the docs?

 On Sunday, 6 May 2012 06:05:58 UTC-5, Aurelijus Useckas wrote:

 Hi, 

 The Bootstrap.min.js in the Trunk layout.html is included in the 
 beginning HEAD section. This didn't allow me to make use of the most, if 
 not all of Bootstrap functions which required .js. Moving the inclusion to 
 the end of the file solved the problem. 



[web2py] Re: response not displaying correctly in iframe

2012-05-06 Thread simon
Thanks. That seems to work. Though I am still curious as to why test.html 
works and test.html/4 does not.

On Sunday, 6 May 2012 18:23:20 UTC+1, Massimo Di Pierro wrote:

 That;s how html understand paths. Do it the safe web2py way:

 iframe src='{{=URL('webpage.html')}}' scrolling=no 
 width=100%/iframe

 On Sunday, 6 May 2012 10:33:58 UTC-5, simon wrote:

 Please can someone explain this.

 When I enter test using the code below then I can see a page with TEST 
 and  CONTENTS which is what I wanted.
 However when I open test/4 it shows three nested iframes  each with TEST

 def test():
 response.view=default/test.html
 return dict()
 def webpage():
 return XML(CONTENTS)

 test.html

 TEST
 iframe src='webpage.html' scrolling=no width=100%/iframe



[web2py] Unit Testing

2012-05-06 Thread Rod Watkins
Hi everyone,

I am fairly new to web2py and python programming, but have had some rather 
wonderful success in the month or so I've been learning it.

I am now preparing to start a real project and want to have unit tests as I 
go.  I've read a bit (will be doing more) about python unit testing 
(doctests, unittest, nose, coverage, selenium), but I want to get some 
expert advise before I fully dive in, if I may. So a few questions:

1. Do you use unit tests?
2. What tools do you use (doctests, unittest, nose, coverage, selenium, 
mocker, or others)?
3. Do you use any of the test runners from the community? (
http://packages.python.org/web2py_utils/test_runner.html,http://packages.python.org/web2py_utils/test_runner.htmlhttp://www.web2pyslices.com/slices/take_slice/142,http://www.web2pyslices.com/slices/take_slice/142http://web2py.com/AlterEgo/default/show/260)
 
Which, if any, would you suggest using?

I'm mainly looking for some guidance about how to proceed, what to study 
and the best manner you've found to do unit tests.  For example, it is 
worth doing anything more than doctests in controllers? If so, what beyond 
them should I learn to use, etc.

Thanks everyone.
Rod



[web2py] Re: response not displaying correctly in iframe

2012-05-06 Thread pbreit
This is *really* weird code.

Can you show us resulting the HTML source?

As Massimo notes, best to use URL() function for URLs. You generally don't 
need this: response.view=default/test.html. Shouldn't matter but you 
could  just do: return 'CONTENTS'

Going to http://myserver.com/myapp/test/4 should be the same as going 
to http://myserver.com/myapp/test. The '4' is simply disregarded since your 
controller doesn't look for it.


[web2py] Re: Bootstrap.min.js

2012-05-06 Thread pbreit
Well, here's the base Bootstrap skeleton:


!DOCTYPE htmlhtml lang=en head meta charset=utf-8 titleBootstrap, 
from Twitter/title meta name=viewport content=width=device-width, 
initial-scale=1.0 meta name=description content= meta name=author 
content=
!-- Le styles -- link 
href=../assets/css/bootstrap.csshttp://twitter.github.com/bootstrap/assets/css/bootstrap.css
 
rel=stylesheet style body { padding-top: 60px; /* 60px to make the 
container go all the way to the bottom of the topbar */ } /style link 
href=../assets/css/bootstrap-responsive.csshttp://twitter.github.com/bootstrap/assets/css/bootstrap-responsive.css
 
rel=stylesheet
!-- Le HTML5 shim, for IE6-8 support of HTML5 elements -- !--[if lt IE 
9] script 
src=http://html5shim.googlecode.com/svn/trunk/html5.js;/script![endif]--
!-- Le fav and touch icons -- link rel=shortcut icon href=
../assets/ico/favicon.icohttp://twitter.github.com/bootstrap/assets/ico/favicon.ico
 link rel=apple-touch-icon-precomposed sizes=144x144 href=
../assets/ico/apple-touch-icon-144-precomposed.pnghttp://twitter.github.com/bootstrap/assets/ico/apple-touch-icon-144-precomposed.png
 link rel=apple-touch-icon-precomposed sizes=114x114 href=
../assets/ico/apple-touch-icon-114-precomposed.pnghttp://twitter.github.com/bootstrap/assets/ico/apple-touch-icon-114-precomposed.png
 link rel=apple-touch-icon-precomposed sizes=72x72 href=
../assets/ico/apple-touch-icon-72-precomposed.pnghttp://twitter.github.com/bootstrap/assets/ico/apple-touch-icon-72-precomposed.png
 link rel=apple-touch-icon-precomposed href=
../assets/ico/apple-touch-icon-57-precomposed.pnghttp://twitter.github.com/bootstrap/assets/ico/apple-touch-icon-57-precomposed.png
 /head
body
div class=navbar navbar-fixed-top div class=navbar-inner div class
=container a class=btn btn-navbar data-toggle=collapse data-target=
.nav-collapse span class=icon-bar/span span class=icon-bar
/span span class=icon-bar/span /a a class=brand 
href=#http://twitter.github.com/bootstrap/examples/starter-template.html#
Project name/a div class=nav-collapse ul class=nav li class=
activea 
href=#http://twitter.github.com/bootstrap/examples/starter-template.html#
Home/a/li lia 
href=#abouthttp://twitter.github.com/bootstrap/examples/starter-template.html#about
About/a/li lia 
href=#contacthttp://twitter.github.com/bootstrap/examples/starter-template.html#contact
Contact/a/li /ul /div!--/.nav-collapse -- /div /div /div
div class=container
h1Bootstrap starter template/h1 pUse this document as a way to quick 
start any new project.br All you get is this message and a barebones HTML 
document./p
/div !-- /container --
!-- Le javascript == -- !-- 
Placed at the end of the document so the pages load faster -- script src=
../assets/js/jquery.jshttp://twitter.github.com/bootstrap/assets/js/jquery.js
/script script 
src=../assets/js/bootstrap-transition.jshttp://twitter.github.com/bootstrap/assets/js/bootstrap-transition.js
/script script 
src=../assets/js/bootstrap-alert.jshttp://twitter.github.com/bootstrap/assets/js/bootstrap-alert.js
/script script 
src=../assets/js/bootstrap-modal.jshttp://twitter.github.com/bootstrap/assets/js/bootstrap-modal.js
/script script 
src=../assets/js/bootstrap-dropdown.jshttp://twitter.github.com/bootstrap/assets/js/bootstrap-dropdown.js
/script script 
src=../assets/js/bootstrap-scrollspy.jshttp://twitter.github.com/bootstrap/assets/js/bootstrap-scrollspy.js
/script script 
src=../assets/js/bootstrap-tab.jshttp://twitter.github.com/bootstrap/assets/js/bootstrap-tab.js
/script script 
src=../assets/js/bootstrap-tooltip.jshttp://twitter.github.com/bootstrap/assets/js/bootstrap-tooltip.js
/script script 
src=../assets/js/bootstrap-popover.jshttp://twitter.github.com/bootstrap/assets/js/bootstrap-popover.js
/script script 
src=../assets/js/bootstrap-button.jshttp://twitter.github.com/bootstrap/assets/js/bootstrap-button.js
/script script 
src=../assets/js/bootstrap-collapse.jshttp://twitter.github.com/bootstrap/assets/js/bootstrap-collapse.js
/script script 
src=../assets/js/bootstrap-carousel.jshttp://twitter.github.com/bootstrap/assets/js/bootstrap-carousel.js
/script script 
src=../assets/js/bootstrap-typeahead.jshttp://twitter.github.com/bootstrap/assets/js/bootstrap-typeahead.js
/script
/body/html


[web2py] Re: Bootstrap.min.js

2012-05-06 Thread Massimo Di Pierro
the web2py bootstrap.min.js should include of the other boostrap-*.js

On Sunday, 6 May 2012 12:56:50 UTC-5, pbreit wrote:

 Well, here's the base Bootstrap skeleton:


 !DOCTYPE htmlhtml lang=en head meta charset=utf-8 
 titleBootstrap, 
 from Twitter/title meta name=viewport content=width=device-width, 
 initial-scale=1.0 meta name=description content= meta name=
 author content=
 !-- Le styles -- link 
 href=../assets/css/bootstrap.csshttp://twitter.github.com/bootstrap/assets/css/bootstrap.css
  
 rel=stylesheet style body { padding-top: 60px; /* 60px to make the 
 container go all the way to the bottom of the topbar */ } /style link 
 href=../assets/css/bootstrap-responsive.csshttp://twitter.github.com/bootstrap/assets/css/bootstrap-responsive.css
  
 rel=stylesheet
 !-- Le HTML5 shim, for IE6-8 support of HTML5 elements -- !--[if lt IE 
 9] script src=http://html5shim.googlecode.com/svn/trunk/html5.js
 /script ![endif]--
 !-- Le fav and touch icons -- link rel=shortcut icon href=
 ../assets/ico/favicon.icohttp://twitter.github.com/bootstrap/assets/ico/favicon.ico
  link rel=apple-touch-icon-precomposed sizes=144x144 href=
 ../assets/ico/apple-touch-icon-144-precomposed.pnghttp://twitter.github.com/bootstrap/assets/ico/apple-touch-icon-144-precomposed.png
  link rel=apple-touch-icon-precomposed sizes=114x114 href=
 ../assets/ico/apple-touch-icon-114-precomposed.pnghttp://twitter.github.com/bootstrap/assets/ico/apple-touch-icon-114-precomposed.png
  link rel=apple-touch-icon-precomposed sizes=72x72 href=
 ../assets/ico/apple-touch-icon-72-precomposed.pnghttp://twitter.github.com/bootstrap/assets/ico/apple-touch-icon-72-precomposed.png
  link rel=apple-touch-icon-precomposed href=
 ../assets/ico/apple-touch-icon-57-precomposed.pnghttp://twitter.github.com/bootstrap/assets/ico/apple-touch-icon-57-precomposed.png
  /head
 body
 div class=navbar navbar-fixed-top div class=navbar-inner div 
 class=container a class=btn btn-navbar data-toggle=collapse 
 data-target=.nav-collapse span class=icon-bar/span span class=
 icon-bar/span span class=icon-bar/span /a a class=brand 
 href=#http://twitter.github.com/bootstrap/examples/starter-template.html#
 Project name/a div class=nav-collapse ul class=nav li class=
 activea 
 href=#http://twitter.github.com/bootstrap/examples/starter-template.html#
 Home/a/li lia 
 href=#abouthttp://twitter.github.com/bootstrap/examples/starter-template.html#about
 About/a/li lia 
 href=#contacthttp://twitter.github.com/bootstrap/examples/starter-template.html#contact
 Contact/a/li /ul /div!--/.nav-collapse -- /div /div /div
 div class=container
 h1Bootstrap starter template/h1 pUse this document as a way to 
 quick start any new project.br All you get is this message and a 
 barebones HTML document./p
 /div !-- /container --
 !-- Le javascript == -- 
 !-- 
 Placed at the end of the document so the pages load faster -- script src
 =../assets/js/jquery.jshttp://twitter.github.com/bootstrap/assets/js/jquery.js
 /script script 
 src=../assets/js/bootstrap-transition.jshttp://twitter.github.com/bootstrap/assets/js/bootstrap-transition.js
 /script script 
 src=../assets/js/bootstrap-alert.jshttp://twitter.github.com/bootstrap/assets/js/bootstrap-alert.js
 /script script 
 src=../assets/js/bootstrap-modal.jshttp://twitter.github.com/bootstrap/assets/js/bootstrap-modal.js
 /script script 
 src=../assets/js/bootstrap-dropdown.jshttp://twitter.github.com/bootstrap/assets/js/bootstrap-dropdown.js
 /script script 
 src=../assets/js/bootstrap-scrollspy.jshttp://twitter.github.com/bootstrap/assets/js/bootstrap-scrollspy.js
 /script script 
 src=../assets/js/bootstrap-tab.jshttp://twitter.github.com/bootstrap/assets/js/bootstrap-tab.js
 /script script 
 src=../assets/js/bootstrap-tooltip.jshttp://twitter.github.com/bootstrap/assets/js/bootstrap-tooltip.js
 /script script 
 src=../assets/js/bootstrap-popover.jshttp://twitter.github.com/bootstrap/assets/js/bootstrap-popover.js
 /script script 
 src=../assets/js/bootstrap-button.jshttp://twitter.github.com/bootstrap/assets/js/bootstrap-button.js
 /script script 
 src=../assets/js/bootstrap-collapse.jshttp://twitter.github.com/bootstrap/assets/js/bootstrap-collapse.js
 /script script 
 src=../assets/js/bootstrap-carousel.jshttp://twitter.github.com/bootstrap/assets/js/bootstrap-carousel.js
 /script script 
 src=../assets/js/bootstrap-typeahead.jshttp://twitter.github.com/bootstrap/assets/js/bootstrap-typeahead.js
 /script
 /body/html



[web2py] Re: Admin interface slow when static dir has a lot of files

2012-05-06 Thread pbreit
I'd suggest putting the images outside the web2py directory or not using 
the web interface.

[web2py] Re: Another misinformed article about web2py

2012-05-06 Thread pbreit
Would making it so that you import request satisfy the author? It does 
seem like web3py (or whatever) whould make more use of import to avoid 
these critiques.

Re: [web2py] Re: Bootstrap.min.js

2012-05-06 Thread Aurelijus
Yes, bootstrap-min.js includes all the goodies, but as a skeleton suggests
it has to be included in the end of a document.

On Sun, May 6, 2012 at 9:03 PM, Massimo Di Pierro 
massimo.dipie...@gmail.com wrote:

 the web2py bootstrap.min.js should include of the other boostrap-*.js


 On Sunday, 6 May 2012 12:56:50 UTC-5, pbreit wrote:

 Well, here's the base Bootstrap skeleton:


 !DOCTYPE htmlhtml lang=en head meta charset=utf-8 
 titleBootstrap,
 from Twitter/title meta name=viewport content=width=device-width,
 initial-scale=1.0 meta name=description content= meta name=
 author content=
 !-- Le styles -- link 
 href=../assets/css/bootstrap.**csshttp://twitter.github.com/bootstrap/assets/css/bootstrap.css
 rel=stylesheet style body { padding-top: 60px; /* 60px to make the
 container go all the way to the bottom of the topbar */ } /style link
 href=../assets/css/bootstrap-**responsive.csshttp://twitter.github.com/bootstrap/assets/css/bootstrap-responsive.css
 rel=stylesheet
 !-- Le HTML5 shim, for IE6-8 support of HTML5 elements -- !--[if lt
 IE 9] script src=http://html5shim.**googlecode.com/svn/trunk/**
 html5.js http://html5shim.googlecode.com/svn/trunk/html5.js/script
 ![endif]--
 !-- Le fav and touch icons -- link rel=shortcut icon href=
 ../assets/ico/favicon.**icohttp://twitter.github.com/bootstrap/assets/ico/favicon.ico
  link rel=apple-touch-icon-**precomposed sizes=144x144 href=
 ../assets/ico/apple-**touch-icon-144-precomposed.pnghttp://twitter.github.com/bootstrap/assets/ico/apple-touch-icon-144-precomposed.png
 ** link rel=apple-touch-icon-**precomposed sizes=114x114 href=
 ../assets/ico/apple-**touch-icon-114-precomposed.pnghttp://twitter.github.com/bootstrap/assets/ico/apple-touch-icon-114-precomposed.png
 ** link rel=apple-touch-icon-**precomposed sizes=72x72 href=
 ../assets/ico/apple-**touch-icon-72-precomposed.pnghttp://twitter.github.com/bootstrap/assets/ico/apple-touch-icon-72-precomposed.png
 ** link rel=apple-touch-icon-**precomposed href=
 ../assets/ico/apple-**touch-icon-57-precomposed.pnghttp://twitter.github.com/bootstrap/assets/ico/apple-touch-icon-57-precomposed.png
 ** /head
 body
 div class=navbar navbar-fixed-top div class=navbar-inner div
 class=container a class=btn btn-navbar data-toggle=collapse
 data-target=.nav-collapse span class=icon-bar/span span class=
 icon-bar/span span class=icon-bar/span /a a class=brand
 href=#http://twitter.github.com/bootstrap/examples/starter-template.html#
 Project name/a div class=nav-collapse ul class=nav li class
 =activea 
 href=#http://twitter.github.com/bootstrap/examples/starter-template.html#
 Home/a/li lia 
 href=#abouthttp://twitter.github.com/bootstrap/examples/starter-template.html#about
 About/a/li lia 
 href=#contacthttp://twitter.github.com/bootstrap/examples/starter-template.html#contact
 Contact/a/**li /ul /div!--/.nav-collapse -- /div /div
 /div
 div class=container
 h1Bootstrap starter template/h1 pUse this document as a way to
 quick start any new project.br All you get is this message and a
 barebones HTML document./p
 /div !-- /container --
 !-- Le javascript ==**
 -- !-- Placed at the end of the document so the pages load faster -- 
 script
 src=../assets/js/jquery.jshttp://twitter.github.com/bootstrap/assets/js/jquery.js
 **/script script 
 src=../assets/js/bootstrap-**transition.jshttp://twitter.github.com/bootstrap/assets/js/bootstrap-transition.js
 /script script 
 src=../assets/js/bootstrap-**alert.jshttp://twitter.github.com/bootstrap/assets/js/bootstrap-alert.js
 /script script 
 src=../assets/js/bootstrap-**modal.jshttp://twitter.github.com/bootstrap/assets/js/bootstrap-modal.js
 /script script 
 src=../assets/js/bootstrap-**dropdown.jshttp://twitter.github.com/bootstrap/assets/js/bootstrap-dropdown.js
 /script script 
 src=../assets/js/bootstrap-**scrollspy.jshttp://twitter.github.com/bootstrap/assets/js/bootstrap-scrollspy.js
 /script script 
 src=../assets/js/bootstrap-**tab.jshttp://twitter.github.com/bootstrap/assets/js/bootstrap-tab.js
 /script script 
 src=../assets/js/bootstrap-**tooltip.jshttp://twitter.github.com/bootstrap/assets/js/bootstrap-tooltip.js
 /script script 
 src=../assets/js/bootstrap-**popover.jshttp://twitter.github.com/bootstrap/assets/js/bootstrap-popover.js
 /script script 
 src=../assets/js/bootstrap-**button.jshttp://twitter.github.com/bootstrap/assets/js/bootstrap-button.js
 /script script 
 src=../assets/js/bootstrap-**collapse.jshttp://twitter.github.com/bootstrap/assets/js/bootstrap-collapse.js
 /script script 
 src=../assets/js/bootstrap-**carousel.jshttp://twitter.github.com/bootstrap/assets/js/bootstrap-carousel.js
 /script script 
 src=../assets/js/bootstrap-**typeahead.jshttp://twitter.github.com/bootstrap/assets/js/bootstrap-typeahead.js
 /script
 /body/html




[web2py] Re: Dynamic Subdomain Routing

2012-05-06 Thread pbreit
You can get the subdomain with request.env.http_host.split('.')[0]

If you always wanted it available, in a model:
subdomain = request.env.http_host.split('.')[0]


[web2py] Re: response not displaying correctly in iframe

2012-05-06 Thread Anthony
I think the same problem as mentioned 
here: https://groups.google.com/d/msg/web2py/eS0bKdwuQuY/-v0lBhtIpPgJ. In 
your iframe, you have src='webpage.html' -- because the URL does not start 
with a /, the browser interprets it as being relative to the current URL. 
So, when the parent page is http://mydomain.com/myapp/default/test, the 
iframe source becomes http://mydomain.com/myapp/default/webpage.html, which 
is what you want. But when the parent page 
is http://mydomain.com/myapp/default/test/4, the iframe source 
is http://mydomain.com/myapp/default/test/webpage.html, which routes to the 
test() function with webpage.html in request.args[0] -- so you're just 
nesting iframes of the same page.

Anthony

On Sunday, May 6, 2012 11:33:58 AM UTC-4, simon wrote:

 Please can someone explain this.

 When I enter test using the code below then I can see a page with TEST 
 and  CONTENTS which is what I wanted.
 However when I open test/4 it shows three nested iframes  each with TEST

 def test():
 response.view=default/test.html
 return dict()
 def webpage():
 return XML(CONTENTS)

 test.html

 TEST
 iframe src='webpage.html' scrolling=no width=100%/iframe



[web2py] Restart web2py from command line

2012-05-06 Thread Yarin
Is there any way to restart web2py from the command line. I'm working on a 
mac, and there's no way to use the GUI to stop or restart the built-in 
rocket server. Currently the best I can do is:

   - Start web2py: python web2py.py -a 'pass' -i 127.0.0.1 -p 8000
   - Stop web2py: kill -SIGTERM {whatever pid was returned from start 
   script}

This is a clumsy process, but one i'm forced to go through many times a day 
when dealing with module development, as there's no other way to ensure a 
clean reload of modules.


Re: [web2py] Re: An insult to web2py ?

2012-05-06 Thread Anthony


 Regarding the editor and editing in production. I was expecting that 
 argument and think that shouldn't be done unless its some extreme 
 emergency. 

OK, so let's say it's there for extreme emergencies. Also, maybe you need 
to make a quick fix on your staging server. There are other times it can 
be convenient that don't involve making changes to a live production site.
 

 One should not put code in production without testing it thoroughly. 

Depends on how important the production system is. Not all websites are 
mission critical applications.
 

 What if your emergency edit in prod introduces a new bug that causes a 
 data loss for the client?

You've got backups, right?

Anyway, we get it -- you don't have any use for the admin editor. It really 
is not the centerpiece of web2py and is not diverting any important 
development resources, so perhaps we can move on. :-)

Anthony


Re: [web2py] Re: An insult to web2py ?

2012-05-06 Thread Anthony


 The dal exposes more details therefore allows you to do more. However, by 
 exposing all these details, you get a tool that is harder to use (in the 
 sense that you have to repeat yourself) for all the other scenarios where 
 you don't need such details.


But what are examples where you need to repeat yourself with the DAL (but 
not with an ORM)?

I've never seen anyone use relational algebra in a real world project.


That doesn't mean the tools you use aren't taking advantage of its 
principles (or failing to do so when they could be).
 

 I've also learned in my experience that database normalization sometimes 
 has to go in order to get, for instance, performance.


Are you suggesting an ORM handles denormalization more easily than the DAL?

You also have to map data from the dal into you business layer by hand.


How so?

Anthony



[web2py] Re: response not displaying correctly in iframe

2012-05-06 Thread simon
Well you only have a small extract of what I am doing. Even so it is a 
little weird so I will explain (any suggestions of alternative ways 
welcome!):

I want to include within my view some of my own buttons and menus on the 
left of the screen; plus show an external web page from the internet.

Having an iframe keeps the two parts isolated and prevents conflicts 
between my CSS and the CSS of the web page.

The iframe source calls a web2py controller which fetches the page from the 
web. This allows me to make some changes to the web page within web2py 
before it is loaded in the iframe. It also gives the iframe has the same 
domain as the parent view which is needed to give the parent javascript 
access the iframe document.

And I set the response.view because I have several controllers each with a 
single view and would rather put all the views in one directory (default); 
whereas normally a controller looks in the view/controller folder.

On Sunday, 6 May 2012 18:54:33 UTC+1, pbreit wrote:

 This is *really* weird code.

 Can you show us resulting the HTML source?

 As Massimo notes, best to use URL() function for URLs. You generally don't 
 need this: response.view=default/test.html. Shouldn't matter but you 
 could  just do: return 'CONTENTS'

 Going to http://myserver.com/myapp/test/4 should be the same as going to 
 http://myserver.com/myapp/test. The '4' is simply disregarded since your 
 controller doesn't look for it.



[web2py] Anyone using flake8 / pyflakes?

2012-05-06 Thread Keith Edmunds
I've just started using flake8 from within vim. Flake8 checks code for
PEP8 conformance and general errors, including undefined names. That means
that running it when editing, say, a web2py controller, lots of warnings
are given:

/path/to/file.py|16| W802 undefined name 'session'

There is an option to suppress reporting of specific errors/warnings,
but that only applies to the PEP8 reporting, not the pyflakes reporting.
Given the implicit import style of web2py (which I'm not complaining
about), this results in lots of spurious errors when checking web2py code,
spoiling an otherwise very useful tool.

Has anyone hacked around with flake8 to suppress the undefined names
warnings?

Notes:
flake8: http://pypi.python.org/pypi/flake8
flake8 vim integration: https://github.com/avidal/flake8.vim
the bug:
https://bitbucket.org/tarek/flake8/issue/14/flake8-fails-to-ignore-errors-warning-from
-- 
You can have everything in life you want if you help enough other people
get what they want - Zig Ziglar. 

Who did you help today?


[web2py] Re: Reloading modules

2012-05-06 Thread Yarin
I think I've figured out the issue I was having with the auto reloader- the 
modules I import into the app do in fact reload, it was their dependancies 
that weren't- so if made a change on a module that was being imported only 
by another module, the changed module wasn't reloaded. 

The solution is to import every module, including dependencies, into your 
app directly. So far it's working..

On Saturday, April 28, 2012 2:40:35 PM UTC-4, Yarin wrote:

 I've been trying this and it is *not* working.

 I put this exact line:
 from gluon.custom_import import track_changes; track_changes(True)

 in my 0.py model file, before any other code. But still any changes I make 
 in my modules do not take effect until I restart server- or if they do it 
 is inconsistently- certainly not on every new page request. Basically, no 
 different than before. 




 On Saturday, April 28, 2012 10:24:21 AM UTC-4, simon wrote:

 from gluon.custom_import import track_changes; track_changes(True)

 On Saturday, 28 April 2012 14:43:42 UTC+1, Yarin wrote:

 For dev purposes, it would be nice to be able to reload modules without 
 having to restart the server- or to have a setting that automatically 
 reloads on each request- Otherwise it's almost impossible to do active 
 module development from within web2py.



Re: [web2py] Re: localhost external machine.

2012-05-06 Thread Mchurch
yes Yogesh, it's  a private network.

I tried on another windows 7 machine, with windows version of web2py and 
everything works perfectly.
m... on the other windows machine i copied all web2py directory from my 
mac.
Is it possible that i must download the windows version instead..??

Il giorno domenica 6 maggio 2012 18:42:02 UTC+2, Yogesh Kamat ha scritto:

 Hello Marco,
 192.168.x.x is a private network IP. Not able to check out..

 Regards,
 Yogesh

 On Sun, May 6, 2012 at 9:39 PM, Mchurch mchurc...@gmail.com wrote:

 ThankYou guys.
 The file was enabled, but doing some more trying i was able to get 
 localhost using public ip 192.168.100.191 (I'm catching all connections 
 with a hotspot and redirecting users to 
 http://192.168.100.191:8000/restaurant/default/show
 Now, on my Mac, doing that, i can see every pictures from my mobile. 
 With windows i can't see images!! I tried with tornado and rocket, but 
 same result.
 I think i'm loosing some path and jquery is getting crazy; may be i must 
 use some absolute path  in this view?
 The server is doing its job, and the logic too, server side is ok, it 
 should be some javascript path

 !DOCTYPE html
 html lang=en
 head
 titleResponsive Image Gallery/title
 meta charset=UTF-8 /
 meta http-equiv=X-UA-Compatible content=IE=edge,chrome=1
 meta name=viewport content=width=device-width, 
 initial-scale=1.0, maximum-scale=1.0, user-scalable=no
 meta name=description content=Responsive Image Gallery with 
 jQuery /
 meta name=keywords content=jquery, carousel, image gallery, 
 slider, responsive, flexible, fluid, resize, css3 /
 meta name=author content=Codrops /
 link rel=shortcut icon href=../favicon.ico
 link rel=stylesheet type=text/css href=
 /{{=request.application}}/static/css/demo.css /
 link rel=stylesheet type=text/css href=
 /{{=request.application}}/static/css/style.css /
 link rel=stylesheet type=text/css href=
 /{{=request.application}}/static/css/elastislide.css /
 link href='
 http://fonts.googleapis.com/css?family=PT+Sans+Narrowv1' rel=
 'stylesheet' type='text/css' /
 link href='http://fonts.googleapis.com/css?family=Pacifico' rel=
 'stylesheet' type='text/css' /
 script type=text/javascript src=
 http://ajax.googleapis.com/ajax/libs/jquery/1.6.4/jquery.min.js;
 /script
 noscript
 style
 .es-carousel ul{
 display:block;
 }
 /style
 /noscript
 script
 $(function() {
  var pgurl = window.location.href.substr(window.location.href.
 lastIndexOf(/)+1);
 $(#nav li a).each(function(){
 controllo=$(this).attr(href).substr($(this).attr(href).
 lastIndexOf(/)+1);
  
   if(controllo == pgurl)
   $(this).addClass(selected);
  })
 });
 /script
 script id=img-wrapper-tmpl type=text/x-jquery-tmpl
 div class=rg-image-wrapper


 div class=rg-image-nav
 a href=# class=rg-image-nav-prevPrevious 
 Image/a
 a href=# class=rg-image-nav-nextNext Image/
 a
 /div
 

 div class=rg-image/div
 div class=rg-loading/div
 div class=rg-caption-wrapper
 div class=rg-caption style=display:none;
 p/p
 /div
 /div
 /div
 /script
 /head
 body
 I CAN SEE THISimg src=
 /{{=request.application}}/static/images/bandiera_italiana.png
 div class=container
 div class=headerdiv class=clr/div/div!-- header 
 --
 div class=content
 div class=rg-image-wrapperdiv class=rg-image-nav/div
 div class=rg-imageimg src=
 /{{=request.application}}/static/images/header-2.jpg/div
 div class=rg-loading style=display: none; /div
 div class=rg-caption-wrapperdiv class=rg-caption style
 =/div/div
  /div
 
 div id=rg-gallery class=rg-gallery
 div class=rg-thumbs 
 !-- Elastislide Carousel Thumbnail Viewer --
 div id=pippo class=
 es-carousel-wrapperbandiere
 div class=es-nav
 span class=es-nav-prevPrevious/span
 span class=es-nav-nextNext/span
 /div
 div class=es-carouselbandiere
 ul{{ for elemento in ciclo:}}
 li
 
 {{immagine=IMG(_src=/+request.application+ /static/images/ + 
 elemento.bandiera)}}
 {{=A(immagine, _href=URL('show', 
 vars=dict(lingua=elemento.id,bandiera=elemento.bandiera)))}}
 /li
  

[web2py] Re: My home made ide

2012-05-06 Thread villas
Thanks for this and I was interested to try it.  

FYI  I got this error:  AttributeError: 'MainPanel' object has no attribute 
'terminal'

Maybe it was the software I was using. Windows XP SP3, Python 2.7 and wx 2.8


[web2py] A good provider

2012-05-06 Thread Michele Comitini
Hello list,

If prefer to manage your machines, clusters and so on this is my suggestion:

http://www.giga-international.com/?show=vserver

I have been using them for almost 2 years and their price is very  for
what you get: very fast networking and powerful VMs and also cheap
real servers.
Support is very  good.  Pricing is simple without surprises.

mic


Re: [web2py] Anyone using flake8 / pyflakes?

2012-05-06 Thread Keith Edmunds
In case anyone's interested, I've posted a quick and dirty hack to fix
this problem at
https://bitbucket.org/tarek/flake8/issue/14/flake8-fails-to-ignore-errors-warning-from#comment-1385353

-- 
You can have everything in life you want if you help enough other people
get what they want - Zig Ziglar. 

Who did you help today?


[web2py] Re: Another misinformed article about web2py

2012-05-06 Thread Massimo Di Pierro
First of the comment about what web2py allegedly does is untrue. Web2py 
does not inject variables in modules. Web2py leaves modules alones and you 
use them normally as in any python program. Web2py simpley does not treats 
models and controllers as modules. They in are not modules at all. They are 
executed in a context not imported.

Yes this is a source of criticism mostly for people who do not understand 
why we do it (to enable hot install and uninstall of apps without 
conflicts). It is better than what other frameworks do (reload module when 
they change and that can cause memory leaks and other problems) and yet do 
not achieve the clean multi-app support that web2py has.

I have tried rewriting web2py without the exec mechanism. It cannot be done 
without giving up some of our unique features. We can make it a little 
cleaner (there is a meta-programming step that can be eliminated). We can 
promote parts of models to modules so that tables are defined once and for 
all. Still working on it anyway. Any feedback is appreciated.

Massimo

On Sunday, 6 May 2012 13:10:36 UTC-5, pbreit wrote:

 Would making it so that you import request satisfy the author? It does 
 seem like web3py (or whatever) whould make more use of import to avoid 
 these critiques.



Re: [web2py] Re: Bootstrap.min.js

2012-05-06 Thread Massimo Di Pierro
Please open a google code ticket about this so you get the credit and we do 
not forget. ;-)


On Sunday, 6 May 2012 13:12:18 UTC-5, Aurelijus Useckas wrote:

 Yes, bootstrap-min.js includes all the goodies, but as a skeleton suggests 
 it has to be included in the end of a document. 

 On Sun, May 6, 2012 at 9:03 PM, Massimo Di Pierro 
 massimo.dipie...@gmail.com wrote:

 the web2py bootstrap.min.js should include of the other boostrap-*.js


 On Sunday, 6 May 2012 12:56:50 UTC-5, pbreit wrote:

 Well, here's the base Bootstrap skeleton:


 !DOCTYPE htmlhtml lang=en head meta charset=utf-8 
 titleBootstrap, 
 from Twitter/title meta name=viewport content=width=device-width, 
 initial-scale=1.0 meta name=description content= meta name=
 author content=
 !-- Le styles -- link 
 href=../assets/css/bootstrap.**csshttp://twitter.github.com/bootstrap/assets/css/bootstrap.css
  
 rel=stylesheet style body { padding-top: 60px; /* 60px to make the 
 container go all the way to the bottom of the topbar */ } /style link 
 href=../assets/css/bootstrap-**responsive.csshttp://twitter.github.com/bootstrap/assets/css/bootstrap-responsive.css
  
 rel=stylesheet 
 !-- Le HTML5 shim, for IE6-8 support of HTML5 elements -- !--[if lt 
 IE 9]  script src=http://html5shim.**googlecode.com/svn/trunk/**
 html5.js http://html5shim.googlecode.com/svn/trunk/html5.js/script 
 ![endif]--
 !-- Le fav and touch icons -- link rel=shortcut icon href=
 ../assets/ico/favicon.**icohttp://twitter.github.com/bootstrap/assets/ico/favicon.ico
  link rel=apple-touch-icon-**precomposed sizes=144x144 href=
 ../assets/ico/apple-**touch-icon-144-precomposed.pnghttp://twitter.github.com/bootstrap/assets/ico/apple-touch-icon-144-precomposed.png
 ** link rel=apple-touch-icon-**precomposed sizes=114x114 href=
 ../assets/ico/apple-**touch-icon-114-precomposed.pnghttp://twitter.github.com/bootstrap/assets/ico/apple-touch-icon-114-precomposed.png
 ** link rel=apple-touch-icon-**precomposed sizes=72x72 href=
 ../assets/ico/apple-**touch-icon-72-precomposed.pnghttp://twitter.github.com/bootstrap/assets/ico/apple-touch-icon-72-precomposed.png
 ** link rel=apple-touch-icon-**precomposed href=
 ../assets/ico/apple-**touch-icon-57-precomposed.pnghttp://twitter.github.com/bootstrap/assets/ico/apple-touch-icon-57-precomposed.png
 ** /head
 body
 div class=navbar navbar-fixed-top div class=navbar-inner div 
 class=container a class=btn btn-navbar data-toggle=collapse 
 data-target=.nav-collapse span class=icon-bar/span span class
 =icon-bar/span span class=icon-bar/span /a a class=brand 
 href=#http://twitter.github.com/bootstrap/examples/starter-template.html#
 Project name/a div class=nav-collapse ul class=nav li class
 =activea 
 href=#http://twitter.github.com/bootstrap/examples/starter-template.html#
 Home/a/li lia 
 href=#abouthttp://twitter.github.com/bootstrap/examples/starter-template.html#about
 About/a/li lia 
 href=#contacthttp://twitter.github.com/bootstrap/examples/starter-template.html#contact
 Contact/a/**li /ul /div!--/.nav-collapse -- /div /div 
 /div
 div class=container 
 h1Bootstrap starter template/h1 pUse this document as a way to 
 quick start any new project.br All you get is this message and a 
 barebones HTML document./p 
 /div !-- /container --
 !-- Le javascript ==** 
 -- !-- Placed at the end of the document so the pages load faster -- 
 script 
 src=../assets/js/jquery.jshttp://twitter.github.com/bootstrap/assets/js/jquery.js
 **/script script 
 src=../assets/js/bootstrap-**transition.jshttp://twitter.github.com/bootstrap/assets/js/bootstrap-transition.js
 /script script 
 src=../assets/js/bootstrap-**alert.jshttp://twitter.github.com/bootstrap/assets/js/bootstrap-alert.js
 /script script 
 src=../assets/js/bootstrap-**modal.jshttp://twitter.github.com/bootstrap/assets/js/bootstrap-modal.js
 /script script 
 src=../assets/js/bootstrap-**dropdown.jshttp://twitter.github.com/bootstrap/assets/js/bootstrap-dropdown.js
 /script script 
 src=../assets/js/bootstrap-**scrollspy.jshttp://twitter.github.com/bootstrap/assets/js/bootstrap-scrollspy.js
 /script script 
 src=../assets/js/bootstrap-**tab.jshttp://twitter.github.com/bootstrap/assets/js/bootstrap-tab.js
 /script script 
 src=../assets/js/bootstrap-**tooltip.jshttp://twitter.github.com/bootstrap/assets/js/bootstrap-tooltip.js
 /script script 
 src=../assets/js/bootstrap-**popover.jshttp://twitter.github.com/bootstrap/assets/js/bootstrap-popover.js
 /script script 
 src=../assets/js/bootstrap-**button.jshttp://twitter.github.com/bootstrap/assets/js/bootstrap-button.js
 /script script 
 src=../assets/js/bootstrap-**collapse.jshttp://twitter.github.com/bootstrap/assets/js/bootstrap-collapse.js
 /script script 
 src=../assets/js/bootstrap-**carousel.jshttp://twitter.github.com/bootstrap/assets/js/bootstrap-carousel.js
 /script script 
 

[web2py] Re: Restart web2py from command line

2012-05-06 Thread Massimo Di Pierro
We can add a restart option.  Anybody wants to try a patch about this? The 
pid is stored in httpserver.pid.


On Sunday, 6 May 2012 14:01:24 UTC-5, Yarin wrote:

 Is there any way to restart web2py from the command line. I'm working on a 
 mac, and there's no way to use the GUI to stop or restart the built-in 
 rocket server. Currently the best I can do is:

- Start web2py: python web2py.py -a 'pass' -i 127.0.0.1 -p 8000
- Stop web2py: kill -SIGTERM {whatever pid was returned from start 
script}

 This is a clumsy process, but one i'm forced to go through many times a 
 day when dealing with module development, as there's no other way to ensure 
 a clean reload of modules.



Re: [web2py] Re: localhost external machine.

2012-05-06 Thread howesc
it sounds to me like a routing problem - when hosting from your mac the 
image links must not be directed back to your mac server.  double check 
that the URLs output in the HTML refer to the proper host.  you might try 
proxying your traffic through something like charles  (google charles 
http proxy) to see all the requests and figure out where they have gone 
astray!


On Sunday, May 6, 2012 1:43:59 PM UTC-7, Mchurch wrote:

 yes Yogesh, it's  a private network.

 I tried on another windows 7 machine, with windows version of web2py and 
 everything works perfectly.
 m... on the other windows machine i copied all web2py directory from 
 my mac.
 Is it possible that i must download the windows version instead..??

 Il giorno domenica 6 maggio 2012 18:42:02 UTC+2, Yogesh Kamat ha scritto:

 Hello Marco,
 192.168.x.x is a private network IP. Not able to check out..

 Regards,
 Yogesh

 On Sun, May 6, 2012 at 9:39 PM, Mchurch mchurc...@gmail.com wrote:

 ThankYou guys.
 The file was enabled, but doing some more trying i was able to get 
 localhost using public ip 192.168.100.191 (I'm catching all connections 
 with a hotspot and redirecting users to 
 http://192.168.100.191:8000/restaurant/default/show
 Now, on my Mac, doing that, i can see every pictures from my mobile. 
 With windows i can't see images!! I tried with tornado and rocket, but 
 same result.
 I think i'm loosing some path and jquery is getting crazy; may be i must 
 use some absolute path  in this view?
 The server is doing its job, and the logic too, server side is ok, it 
 should be some javascript path

 !DOCTYPE html
 html lang=en
 head
 titleResponsive Image Gallery/title
 meta charset=UTF-8 /
 meta http-equiv=X-UA-Compatible content=IE=edge,chrome=1
 meta name=viewport content=width=device-width, 
 initial-scale=1.0, maximum-scale=1.0, user-scalable=no
 meta name=description content=Responsive Image Gallery with 
 jQuery /
 meta name=keywords content=jquery, carousel, image gallery, 
 slider, responsive, flexible, fluid, resize, css3 /
 meta name=author content=Codrops /
 link rel=shortcut icon href=../favicon.ico
 link rel=stylesheet type=text/css href=
 /{{=request.application}}/static/css/demo.css /
 link rel=stylesheet type=text/css href=
 /{{=request.application}}/static/css/style.css /
 link rel=stylesheet type=text/css href=
 /{{=request.application}}/static/css/elastislide.css /
 link href='
 http://fonts.googleapis.com/css?family=PT+Sans+Narrowv1' rel=
 'stylesheet' type='text/css' /
 link href='http://fonts.googleapis.com/css?family=Pacifico' rel
 ='stylesheet' type='text/css' /
 script type=text/javascript src=
 http://ajax.googleapis.com/ajax/libs/jquery/1.6.4/jquery.min.js;
 /script
 noscript
 style
 .es-carousel ul{
 display:block;
 }
 /style
 /noscript
 script
 $(function() {
  var pgurl = window.location.href.substr(window.location.href.
 lastIndexOf(/)+1);
 $(#nav li a).each(function(){
 controllo=$(this).attr(href).substr($(this).attr(href).
 lastIndexOf(/)+1);
  
   if(controllo == pgurl)
   $(this).addClass(selected);
  })
 });
 /script
 script id=img-wrapper-tmpl type=text/x-jquery-tmpl
 div class=rg-image-wrapper


 div class=rg-image-nav
 a href=# class=rg-image-nav-prevPrevious 
 Image/a
 a href=# class=rg-image-nav-nextNext 
 Image/a
 /div
 

 div class=rg-image/div
 div class=rg-loading/div
 div class=rg-caption-wrapper
 div class=rg-caption style=display:none;
 p/p
 /div
 /div
 /div
 /script
 /head
 body
 I CAN SEE THISimg src=
 /{{=request.application}}/static/images/bandiera_italiana.png
 div class=container
 div class=headerdiv class=clr/div/div!-- 
 header --
 div class=content
 div class=rg-image-wrapperdiv class=rg-image-nav/div
 div class=rg-imageimg src=
 /{{=request.application}}/static/images/header-2.jpg/div
 div class=rg-loading style=display: none; /div
 div class=rg-caption-wrapperdiv class=rg-caption 
 style=/div/div
  /div
 
 div id=rg-gallery class=rg-gallery
 div class=rg-thumbs 
 !-- Elastislide Carousel Thumbnail Viewer --
 div id=pippo class=
 es-carousel-wrapperbandiere
 div class=es-nav
 span class=es-nav-prevPrevious
 /span
 span class=es-nav-nextNext/span
 /div

[web2py] Re: Unable to restart Web2py on Mac

2012-05-06 Thread howesc
you may dislike my answerbut i have a shell script that passes the 
parms to web2py that i want.  i launch it via terminal, and i ctrl-c to 
kill and then restart.  i find that much faster than waiting for the tcl 
window to load (and i can share the script with my coding team and we don't 
have to ask what our settings are when debugging things).

so i have no real answer about the tcl interface.  sorry about that.

cfh

On Sunday, May 6, 2012 7:28:30 AM UTC-7, Yarin wrote:

 This is still broken:

 I'm running web2py with the built-in Rocket server locally on my Mac. When 
 I click the stop server button on the server window, and then click 
 start server to restart, I get the following:

 ERROR:Rocket.Errors.Port8000:Socket 127.0.0.1:8000 in use by other 
 process and it won't share.
 please visit:
 http://127.0.0.1:8000
 starting browser...
 WARNING:Rocket.Errors.Port8000:Listener started when not ready.

 The only way I can get past that is to quit Python.

 Is there a way to restart web2py from the command line without having to 
 quit python each time?

 On Thursday, February 17, 2011 4:10:21 PM UTC-5, pbreit wrote:

 Did anyone figure out how to stop and start Web2py from the console on a 
 Mac? When I do it, it doesn't work when it starts back up. It stalls when 
 it opens up the browser window and tries to go to my home page. I remember 
 some discussion about processes not shutting down quickly or at all. Is 
 there any solution?

 I end up having to quit and restart web2py.app every time.



[web2py] Admin Interface suggestions

2012-05-06 Thread Larry Weinberg
Once again I am LOVING web2py.  It's transformational technology.

I do have some admin interface suggestions:

1 - It would be very nice if all views in the admin interface included a 
single horizontal line near the top that had links back to the last 4 or 5 
edited files to make it easier to bounce back and forth.

2 - The collapsed state of the groupings should be remembered.  I rarely 
(never) need to see the language files, for example, and they are above the 
javascript and css files.

3 - The most often edited groups should be at the top (even though the db 
group is conceptually first.  Maybe the DB group should be collapsed if it 
needs to be first for new users.
I typically edit the views and style sheets most often, followed by the 
controllers.

4 - When editing a view it would be great if there was a popup to the list 
of style sheets and javascript files being included by the view.

5 -  Something to think about:  the admin interface could display in two 
columns optionally.  That would make many of the files visible without 
scrolling

6 - The default text editing area for a file could be larger.  Maybe there 
should be an alternate view of it that removes the large hotkey display.

More to come



Re: [web2py] Re: Restart web2py from command line

2012-05-06 Thread Jonathan Lundell
The Fedora rc file has some restart logic, I think.

On May 6, 2012, at 5:44 PM, Massimo Di Pierro massimo.dipie...@gmail.com 
wrote:

 We can add a restart option.  Anybody wants to try a patch about this? The 
 pid is stored in httpserver.pid.
 
 
 On Sunday, 6 May 2012 14:01:24 UTC-5, Yarin wrote:
 Is there any way to restart web2py from the command line. I'm working on a 
 mac, and there's no way to use the GUI to stop or restart the built-in rocket 
 server. Currently the best I can do is:
 Start web2py: python web2py.py -a 'pass' -i 127.0.0.1 -p 8000
 Stop web2py: kill -SIGTERM {whatever pid was returned from start script}
 This is a clumsy process, but one i'm forced to go through many times a day 
 when dealing with module development, as there's no other way to ensure a 
 clean reload of modules.


[web2py] orderby from 2 tables

2012-05-06 Thread CtrlSoft
hi, i have 2 tables both has added_on  field

i need last 'n'(lets assume n=5) rows from both tables ordered by added_on. 
it can be 1 from first table and 4 from second or 2|3

rows1 =db(db.table1).select(orderby=~db.table1.added_on, limitby=(0,5))
rows2 =db(db.table2).select(orderby=~db.table2.added_on, limitby=(0,5)) 

i need smth like this

 rows = rows1+rows2 
 rows-orderby(added_on)

 return dict(first 5 row in rows)

how to do this in a smarter way?




[web2py] Re: orderby from 2 tables

2012-05-06 Thread Massimo Di Pierro
Given

rows1 =db(db.table1).select(orderby=~db.table1.added_on, limitby=(0,5))
rows2 =db(db.table2).select(orderby=~db.table2.added_on, limitby=(0,5)) 

you can do

rows = rows1|rows2 # if you want to discard repeated values
rows = rows1rows2 # if you do not want to discard repeated values

rows = rows.sort(lambda row: row.added_on)

then return dict(rows=rows)

On Sunday, 6 May 2012 20:08:18 UTC-5, CtrlSoft wrote:

 hi, i have 2 tables both has added_on  field

 i need last 'n'(lets assume n=5) rows from both tables ordered by 
 added_on. it can be 1 from first table and 4 from second or 2|3

 rows1 =db(db.table1).select(orderby=~db.table1.added_on, limitby=(0,5))
 rows2 =db(db.table2).select(orderby=~db.table2.added_on, limitby=(0,5)) 

 i need smth like this

  rows = rows1+rows2 
  rows-orderby(added_on)

  return dict(first 5 row in rows)

 how to do this in a smarter way?




Re: [web2py] Re: Restart web2py from command line

2012-05-06 Thread Jonathan Lundell
On May 6, 2012, at 7:30 PM, Jonathan Lundell wrote:
 The Fedora rc file has some restart logic, I think.

scripts/web2py.archlinux.sh and web2py.fedora.sh

 
 On May 6, 2012, at 5:44 PM, Massimo Di Pierro massimo.dipie...@gmail.com 
 wrote:
 
 We can add a restart option.  Anybody wants to try a patch about this? The 
 pid is stored in httpserver.pid.
 
 
 On Sunday, 6 May 2012 14:01:24 UTC-5, Yarin wrote:
 Is there any way to restart web2py from the command line. I'm working on a 
 mac, and there's no way to use the GUI to stop or restart the built-in 
 rocket server. Currently the best I can do is:
 Start web2py: python web2py.py -a 'pass' -i 127.0.0.1 -p 8000
 Stop web2py: kill -SIGTERM {whatever pid was returned from start script}
 This is a clumsy process, but one i'm forced to go through many times a day 
 when dealing with module development, as there's no other way to ensure a 
 clean reload of modules.




[web2py] Re: Restart web2py from command line

2012-05-06 Thread pbreit
I have an alias in my profile:
alias web2py='cd ~/web2py; python web2py.py -a recycle -i 127.0.0.1 -p 
8001'

To stop I just press ctrl-c.


Re: [web2py] Re: localhost external machine.

2012-05-06 Thread Yogesh
Marco, just export w2p file from the admin login of web2py.
Then add the module normally on the windows machine..

Magic of web2py hehe..

On Mon, May 7, 2012 at 2:13 AM, Mchurch mchurc...@gmail.com wrote:

 yes Yogesh, it's  a private network.

 I tried on another windows 7 machine, with windows version of web2py and
 everything works perfectly.
 m... on the other windows machine i copied all web2py directory from
 my mac.
 Is it possible that i must download the windows version instead..??

 Il giorno domenica 6 maggio 2012 18:42:02 UTC+2, Yogesh Kamat ha scritto:

 Hello Marco,
 192.168.x.x is a private network IP. Not able to check out..

 Regards,
 Yogesh

 On Sun, May 6, 2012 at 9:39 PM, Mchurch mchurc...@gmail.com wrote:

 ThankYou guys.
 The file was enabled, but doing some more trying i was able to get
 localhost using public ip 192.168.100.191 (I'm catching all connections
 with a hotspot and redirecting users to http://192.168.100.191:8000/**
 restaurant/default/showhttp://192.168.100.191:8000/restaurant/default/show
 Now, on my Mac, doing that, i can see every pictures from my mobile.
 With windows i can't see images!! I tried with tornado and rocket, but
 same result.
 I think i'm loosing some path and jquery is getting crazy; may be i must
 use some absolute path  in this view?
 The server is doing its job, and the logic too, server side is ok, it
 should be some javascript path

 !DOCTYPE html
 html lang=en
 head
 titleResponsive Image Gallery/title
 meta charset=UTF-8 /
 meta http-equiv=X-UA-Compatible content=IE=edge,chrome=1
 meta name=viewport content=width=device-width,
 initial-scale=1.0, maximum-scale=1.0, user-scalable=no
 meta name=description content=Responsive Image Gallery with
 jQuery /
 meta name=keywords content=jquery, carousel, image gallery,
 slider, responsive, flexible, fluid, resize, css3 /
 meta name=author content=Codrops /
 link rel=shortcut icon href=../favicon.ico
 link rel=stylesheet type=text/css href=
 /{{=request.application}**}/static/css/demo.css /
 link rel=stylesheet type=text/css href=
 /{{=request.application}**}/static/css/style.css /
 link rel=stylesheet type=text/css href=
 /{{=request.application}**}/static/css/elastislide.css /
 link href='http://fonts.googleapis.**
 com/css?family=PT+Sans+Narrow**v1http://fonts.googleapis.com/css?family=PT+Sans+Narrowv1
 ' rel='stylesheet' type='text/css' /
 link 
 href='http://fonts.googleapis.**com/css?family=Pacificohttp://fonts.googleapis.com/css?family=Pacifico
 ' rel='stylesheet' type='text/css' /
 script type=text/javascript src=http://ajax.googleapis.**
 com/ajax/libs/jquery/1.6.4/**jquery.min.jshttp://ajax.googleapis.com/ajax/libs/jquery/1.6.4/jquery.min.js
 /script
 noscript
 style
 .es-carousel ul{
 display:block;
 }
 /style
 /noscript
 script
 $(function() {
  var pgurl = window.location.href.substr(wi**ndow.location.href.
 lastIndexOf**(/)+1);
 $(#nav li a).each(function(){
 controllo=$(this).attr(href)**.substr($(this).attr(href).l**
 astIndexOf(/)+1);

   if(controllo == pgurl)
   $(this).addClass(selected);
  })
 });
 /script
 script id=img-wrapper-tmpl type=text/x-jquery-tmpl
 div class=rg-image-wrapper


 div class=rg-image-nav
 a href=# class=rg-image-nav-prevPrev**ious
 Image/a
 a href=# class=rg-image-nav-nextNext
 Image/a
 /div


 div class=rg-image/div
 div class=rg-loading/div
 div class=rg-caption-wrapper
 div class=rg-caption style=display:none;
 p/p
 /div
 /div
 /div
 /script
 /head
 body
 I CAN SEE THISimg src=/{{=request.application}}**
 /static/images/bandiera_**italiana.png
 div class=container
 div class=headerdiv class=clr/div/div!--
 header --
 div class=content
 div class=rg-image-wrapperdiv class=rg-image-nav/div
 div class=rg-imageimg src=/{{=request.application}}**
 /static/images/header-2.jpg**/div
 div class=rg-loading style=display: none; /div
 div class=rg-caption-wrapper**div class=rg-caption
 style=/div/div
  /div

 div id=rg-gallery class=rg-gallery
 div class=rg-thumbs
 !-- Elastislide Carousel Thumbnail Viewer --
 div id=pippo class=es-carousel-**
 wrapperbandiere
 div class=es-nav
 span class=es-nav-prevPrevious/**
 span
 span class=es-nav-nextNext/**span
 /div
 div 

Re: [web2py] Re: Another misinformed article about web2py

2012-05-06 Thread Yogesh
Massimo,

That's what i respect of you.. To the point explanation. Cheers!!!

Regards,
*Yogesh *

On Mon, May 7, 2012 at 4:12 AM, Massimo Di Pierro 
massimo.dipie...@gmail.com wrote:

 First of the comment about what web2py allegedly does is untrue. Web2py
 does not inject variables in modules. Web2py leaves modules alones and you
 use them normally as in any python program. Web2py simpley does not treats
 models and controllers as modules. They in are not modules at all. They are
 executed in a context not imported.

 Yes this is a source of criticism mostly for people who do not understand
 why we do it (to enable hot install and uninstall of apps without
 conflicts). It is better than what other frameworks do (reload module when
 they change and that can cause memory leaks and other problems) and yet do
 not achieve the clean multi-app support that web2py has.

 I have tried rewriting web2py without the exec mechanism. It cannot be
 done without giving up some of our unique features. We can make it a little
 cleaner (there is a meta-programming step that can be eliminated). We can
 promote parts of models to modules so that tables are defined once and for
 all. Still working on it anyway. Any feedback is appreciated.

 Massimo

 On Sunday, 6 May 2012 13:10:36 UTC-5, pbreit wrote:

 Would making it so that you import request satisfy the author? It does
 seem like web3py (or whatever) whould make more use of import to avoid
 these critiques.




[web2py] Re: Unable to restart Web2py on Mac

2012-05-06 Thread Annet
I had the same problem in October 2010:

https://groups.google.com/forum/?fromgroups#!searchin/web2py/annet$20other$20process/web2py/Zc53Lx85g50/P1CJjLFJuUcJ

Back then it was qualified as an OS X weirdness ;-)


Regards,

Annet


Re: [web2py] Re: Bootstrap.min.js

2012-05-06 Thread Annet
I started working with bootstrap 4 weeks ago and didn't make use of the 
version in trunk. I just integrated the bootstrap skeleton into web2py's 
layout.html and web2py_ajax.html (just renamed them scaffold.html and 
scaffold_ajax.html).  In the scaffold.html view:

script src={{=URL('static','js/modernizr.custom.js')}}/script  

  !-- include stylesheets --
  {{
  response.files.append(URL('static','bootstrap/css/bootstrap.css'))
  }}
  style type=text/css
body {padding-top: 20px; padding-bottom: 40px;}
  /style
  {{
  
response.files.append(URL('static','bootstrap/css/bootstrap-responsive.css'))
  }}

  {{include 'scaffold_ajax.html'}}
  
  !-- uncomment here to load jquery-ui ...


and in scaffold_ajax.html:

response.files.insert(0,URL('static','js/jquery.js'))
if calendar_function:
  response.files.insert(1,URL('static','css/calendar.css'))
  response.files.insert(2,URL('static','js/calendar.js'))
pass
  response.files.insert(4,URL('static','bootstrap/js/bootstrap.min.js'))


Kind regards,

Annet


Re: [web2py] Re: Bootstrap.min.js

2012-05-06 Thread Massimo Di Pierro
I think we have 4 people now working on this. Let's move this discussion to 
web2py-developers. Please copy your email there.

On Monday, 7 May 2012 00:18:35 UTC-5, Annet wrote:

 I started working with bootstrap 4 weeks ago and didn't make use of the 
 version in trunk. I just integrated the bootstrap skeleton into web2py's 
 layout.html and web2py_ajax.html (just renamed them scaffold.html and 
 scaffold_ajax.html).  In the scaffold.html view:

 script src={{=URL('static','js/modernizr.custom.js')}}/script  

   !-- include stylesheets --
   {{
   response.files.append(URL('static','bootstrap/css/bootstrap.css'))
   }}
   style type=text/css
 body {padding-top: 20px; padding-bottom: 40px;}
   /style
   {{
   
 response.files.append(URL('static','bootstrap/css/bootstrap-responsive.css'))
   }}

   {{include 'scaffold_ajax.html'}}
   
   !-- uncomment here to load jquery-ui ...


 and in scaffold_ajax.html:

 response.files.insert(0,URL('static','js/jquery.js'))
 if calendar_function:
   response.files.insert(1,URL('static','css/calendar.css'))
   response.files.insert(2,URL('static','js/calendar.js'))
 pass
   response.files.insert(4,URL('static','bootstrap/js/bootstrap.min.js'))


 Kind regards,

 Annet



[web2py] Re: TypeError: 'instancemethod' object is unsubscriptable

2012-05-06 Thread Annet
Massimo,

I tried both solutions, they both result in the same error:

Traceback (most recent call last):
  File /Library/Python/2.5/site-packages/web2py/gluon/restricted.py, line 
204, in restricted
ccode = compile2(code,layer)
  File /Library/Python/2.5/site-packages/web2py/gluon/restricted.py, line 
189, in compile2
return compile(code.rstrip().replace('\r\n','\n')+'\n', layer, 'exec')
  File 
/Library/Python/2.5/site-packages/web2py/applications/bootstrap/views/generic.html
 http://127.0.0.1:8000/admin/default/edit/bootstrap/views/generic.html, line 
115
response.write('\n\n', escape=False)
   ^
SyntaxError: invalid syntax



Kind regards,

Annet.


Re: [web2py] Re: localhost external machine.

2012-05-06 Thread Marco Dellachiesa
I'll try asap!!
Ps. I'm in Love with web2py, ma hehehe.
Tnx!
Il giorno 07/mag/2012 06:18, Yogesh yogesh@gmail.com ha scritto:

 Marco, just export w2p file from the admin login of web2py.
 Then add the module normally on the windows machine..

 Magic of web2py hehe..

 On Mon, May 7, 2012 at 2:13 AM, Mchurch mchurc...@gmail.com wrote:

 yes Yogesh, it's  a private network.

 I tried on another windows 7 machine, with windows version of web2py and
 everything works perfectly.
 m... on the other windows machine i copied all web2py directory from
 my mac.
 Is it possible that i must download the windows version instead..??

 Il giorno domenica 6 maggio 2012 18:42:02 UTC+2, Yogesh Kamat ha scritto:

 Hello Marco,
 192.168.x.x is a private network IP. Not able to check out..

 Regards,
 Yogesh

 On Sun, May 6, 2012 at 9:39 PM, Mchurch mchurc...@gmail.com wrote:

 ThankYou guys.
 The file was enabled, but doing some more trying i was able to get
 localhost using public ip 192.168.100.191 (I'm catching all connections
 with a hotspot and redirecting users to http://192.168.100.191:8000/**
 restaurant/default/showhttp://192.168.100.191:8000/restaurant/default/show
 Now, on my Mac, doing that, i can see every pictures from my mobile.
 With windows i can't see images!! I tried with tornado and rocket, but
 same result.
 I think i'm loosing some path and jquery is getting crazy; may be i
 must use some absolute path  in this view?
 The server is doing its job, and the logic too, server side is ok, it
 should be some javascript path

 !DOCTYPE html
 html lang=en
 head
 titleResponsive Image Gallery/title
 meta charset=UTF-8 /
 meta http-equiv=X-UA-Compatible content=IE=edge,chrome=1
 meta name=viewport content=width=device-width,
 initial-scale=1.0, maximum-scale=1.0, user-scalable=no
 meta name=description content=Responsive Image Gallery
 with jQuery /
 meta name=keywords content=jquery, carousel, image
 gallery, slider, responsive, flexible, fluid, resize, css3 /
 meta name=author content=Codrops /
 link rel=shortcut icon href=../favicon.ico
 link rel=stylesheet type=text/css href=
 /{{=request.application}**}/static/css/demo.css /
 link rel=stylesheet type=text/css href=
 /{{=request.application}**}/static/css/style.css /
 link rel=stylesheet type=text/css href=
 /{{=request.application}**}/static/css/elastislide.css /
 link href='http://fonts.googleapis.**
 com/css?family=PT+Sans+Narrow**v1http://fonts.googleapis.com/css?family=PT+Sans+Narrowv1
 ' rel='stylesheet' type='text/css' /
 link 
 href='http://fonts.googleapis.**com/css?family=Pacificohttp://fonts.googleapis.com/css?family=Pacifico
 ' rel='stylesheet' type='text/css' /
 script type=text/javascript src=http://ajax.googleapis.**
 com/ajax/libs/jquery/1.6.4/**jquery.min.jshttp://ajax.googleapis.com/ajax/libs/jquery/1.6.4/jquery.min.js
 /script
 noscript
 style
 .es-carousel ul{
 display:block;
 }
 /style
 /noscript
 script
 $(function() {
  var pgurl = window.location.href.substr(wi**ndow.location.href.
 lastIndexOf**(/)+1);
 $(#nav li a).each(function(){
 controllo=$(this).attr(href)**.substr($(this).attr(href).l*
 *astIndexOf(/)+1);

   if(controllo == pgurl)
   $(this).addClass(selected);
  })
 });
 /script
 script id=img-wrapper-tmpl type=text/x-jquery-tmpl
 div class=rg-image-wrapper


 div class=rg-image-nav
 a href=# class=rg-image-nav-prevPrev**
 ious Image/a
 a href=# class=rg-image-nav-nextNext
 Image/a
 /div


 div class=rg-image/div
 div class=rg-loading/div
 div class=rg-caption-wrapper
 div class=rg-caption style=display:none;
 p/p
 /div
 /div
 /div
 /script
 /head
 body
 I CAN SEE THISimg src=/{{=request.application}}**
 /static/images/bandiera_**italiana.png
 div class=container
 div class=headerdiv class=clr/div/div!--
 header --
 div class=content
 div class=rg-image-wrapperdiv class=rg-image-nav/div
 div class=rg-imageimg src=/{{=request.application}}**
 /static/images/header-2.jpg**/div
 div class=rg-loading style=display: none; /div
 div class=rg-caption-wrapper**div class=rg-caption
 style=/div/div
  /div

 div id=rg-gallery class=rg-gallery
 div class=rg-thumbs
 !-- Elastislide Carousel Thumbnail Viewer --
 div id=pippo class=es-carousel-**
 wrapperbandiere
 div class=es-nav
 span class=es-nav-prevPrevious/**
 span
 

[web2py] Re: Another misinformed article about web2py

2012-05-06 Thread Gour
On Sun, 6 May 2012 15:42:14 -0700 (PDT)
Massimo Di Pierro
massimo.dipie...@gmail.com wrote:

 Yes this is a source of criticism mostly for people who do not
 understand why we do it (to enable hot install and uninstall of apps
 without conflicts). It is better than what other frameworks do
 (reload module when they change and that can cause memory leaks and
 other problems) and yet do not achieve the clean multi-app support
 that web2py has.

That's the point...Why making web2py look like 'other frameworks?

 Still working on it anyway. Any feedback is appreciated.

It seems that web2py is gathering new followers despite of such
'criticism' and it's good to have choices...there are plenty of 'em, so.
pls. stay with you design concepts...including built-in editor. ;)


Sincerely,
Gour

-- 
A person who is not disturbed by the incessant flow of 
desires — that enter like rivers into the ocean, which is 
ever being filled but is always still — can alone achieve 
peace, and not the man who strives to satisfy such desires.

http://atmarama.net | Hlapicina (Croatia) | GPG: 52B5C810


signature.asc
Description: PGP signature