Expert-Python : Configure python with apache2
Apache with python, If you want to run your python code with apache hosting then your web server must loaded mod_python package with Apache Server. Need to configure….. 1. sudo gedit /etc/apache2/sites-available/default LoadModule python_module modules/mod_python.so <Directory /var/www/python/> Options Indexes FollowSymLinks MultiViews AllowOverride None Order allow,deny allow from all AddHandler mod_python .py PythonHandler mod_python.publisher [...]
Read MoreEtherpad API Jquery JSON call-jquery-cross-domain-ajax-call
$.ajax({ url: “http://beta.etherpad.org/api/1/setText/”, dataType: ‘jsonp’, data: {apikey:’etherpadEVL’,padID:’test’,text:’working treee’}, crossDomain: true, success: function(e){console.log(e)} }); Like Unlike
Read MoreStartup(s) Are Creating A New Platform Of The World For IT
It remains that, from the same principles, I now demonstrate the frame of the System of the World. – Isaac Newton The practice of IT reminds me a lot of the practice of science before Isaac Newton. Aristotelianism was dead, but there was nothing to replace it. Then Newton came along, created a scientific revolution with [...]
Read MoreOpenERP Web module tips
When we merging openerp web modules below things need to care. Like we are going to merge two different web module web_module1 and web_module2 Then both module have own javascript like openerp.web_module1 and openerp.web_module2 So on merge time do not copy one js in other module and don’t give its link in __openerp__.py. Instead of do batter [...]
Read MoreOpenERP Create Web Module Steps
OpenERP Web Module. To build web module you have to create a module at server addons. You need to first create __init__.py and __openerp__.py file similar as server addons. Where __openerp__.py have more parameters likes { “name”: “web_footer”, “category” : “Hidden”, “description”:’Openerp web new footer links’, “version”: “2.0″, “depends”: ['web','project'], ‘qweb’ : ['static/src/xml/footer.xml'], “css”: [], [...]
Read MoreOpenERP WEb : RPC Call
OpenERP Web Completely Based on rpc calls. To call any rpc service you have to use code like… var self = this; self.rpc(“/web/webclient/login”,{userid:’fp’,password:’big_politician’},function(data){ console.log(data); }); This way you can use any rpc methods where first parameter is url to method, then second one is actual data need to pass, where last one is callback function. [...]
Read MoreGet Milliseconds
[ PHPtime()] World most popular language php. RubyTime.now (or Time.new). To display the epoch: Time.now.to_i Pythonimport time first, then time.time() Javalong epoch = System.currentTimeMillis()/1000; Microsoft .NET C#epoch = (DateTime.Now.ToUniversalTime().Ticks – 621355968000000000) / 10000000; VBScript/ASPDateDiff(“s”, “01/01/1970 00:00:00″, Now())Ras.numeric(Sys.time()) Erlangcalendar:datetime_to_gregorian_seconds(calendar:now_to_universal_time( now()))-719528*24*3600. MySQLSELECT unix_timestamp(now()) More info (+ negative epochs) PostgreSQLSELECT extract(epoch FROM now()); Oracle PL/SQLSELECT (SYSDATE – TO_DATE(’01/01/1970 00:00:00′, ‘MM-DD-YYYY HH24:MI:SS’)) * 24 * [...]
Read More