i encountered an issue and can't seem to be able to solve it.
i downloaded the cURL from http://winampplugins.co.uk/curl/
and mapped my sys path to it which runs at 7.49.1 but my PHP is still running 7.42.1
How can i map or point the latest CURL to my php?
any pointer are greatly appreciated.
Cheers
As far as I know there is no such thing as downloading vanilla cURL and binding it with PHP. You need PHP version of cURL.
Step by Step
Step 1
Download for 32-bit:
http://windows.php.net/downloads/releases/php-5.6.7-Win32-VC11-x86.zip
Download for 64-bit:
http://windows.php.net/downloads/releases/php-5.6.7-Win32-VC11-x64.zip
Step 2
Extract File (Overwrite file - It is a good idea to keep a backup of
the file in case something fails): /etx/php_curl.dll into
C:\wamp\bin\php\php5.5.12\ext\
NOTE: your phpx.x.x folder might be different (depends on your php version)
Step 3
Restart Apache from WAMP Control Panel
Source
Is there any way to have Cassandra PDO at Windows with Wamp?
This is for development purposes I don't want to install Linux and change all the environment.
https://code.google.com/a/apache-extras.org/p/cassandra-pdo/
I'm using Windows 7 (64 Bit), Wamp 2.5, PHP 5.5.
OK, here's what I found out:
1) It's totally possible
2) The docs that appear in the first google search results are a bit obsolete
Start by downloading the latest Datastax Community Cassandra here:
http://planetcassandra.org/cassandra/
Install & setup properly. In fact, most of the configuration is done by the installer, you just have to edit the apache-cassandra/conf/cassandra.yaml file to find all paths to /var/lib... and change those into something like d:/cassandra/... That includes "commitlog", "data", "saved_caches". Restart the Cassandra service, examine the logs. Mine shown no problem. The OpsCenter at ...:8888/opscenter/index.html was working fine, showing one node online.
Now, the PHP part.
There's a sneaky thing called Thrift. From what I've learned today (I first heard about Cassandra and Thrift yesterday), it's a way describe a binary protocol of connecting to some online service, in this case, to Cassandra. It will basically generate PHP files that will provide all the connectivity you need from PHP itself (no extensions needed).
You will need:
1) The Thrift PHP libs
2) The .exe Thrift compiler
Both can be downloaded here:
https://thrift.apache.org/download
Then use the following command to compile PHP files that will act as a "driver" to connect your PHP applications to Cassandra:
thrift --gen php D:\DataStaxCommunity\apache-cassandra\interface\cassandra.thrift
Put the result in some PHP include_path folder.
Also, find the PHP Thrift libs (in the libs archive from the same download page) and put those in a folder accessible to your script (e.g. include_path or the project folder).
Refer this page:
thrift.apache.org/lib/php
I guess that should help!
I have same problem as you, but when i tried this method, it works correctly for me.
Reference link
Here is a code example, very easy to understand :
<?php
require_once 'Cassandra/Cassandra.php';
$o_cassandra = new Cassandra();
$s_server_host = '127.0.0.1'; // Localhost
$i_server_port = 9042;
$s_server_username = ''; // We don't use username
$s_server_password = ''; // We don't use password
$s_server_keyspace = 'cassandra_tests';
$o_cassandra->connect($s_server_host, $s_server_username, $s_server_password, $s_server_keyspace, $i_server_port);
$s_cql = "CREATE TABLE carles_test_table (s_thekey text, s_column1 text, s_column2 text,PRIMARY KEY (s_thekey));";
$st_results = $o_cassandra->query($s_cql);
I have a site, where users sign up. After that they get a great product offer, and I would like to allow them to use from my site "Google connect button" and invite their friends and contacts via Google network.
How can I do that?
Follow up
Sample i found
ex: http://www.dumpsquestions.com/testing/wp-content/themes/ModulaBlueGiant/open/example.php
According to your advise i found that, it allowes a lot ?
Free import contacts (addressbook) script from email providers like
Libero, Interia, Azet, Lycos, AOL, Bordermail, Doramail, Freemail, Kids, Rambler, Mail.ru, Care2, Grafitti, Walla, LinkedIn,
Inbox.com, Mail2World, Meta, IndiaTimes, Sapo.pt, Live/Hotmail, 5Fm, Netaddress, Rediff,
Yahoo!, Aussiemail, KataMail, Gawab, GMX.net, Terra, Uk2, Apropo, Popstarmail, Mynet.com,
YouTube, Bigstring, OperaMail, Mail.com, Mail.in, Nz11, Inet, Pochta, Web.de, Canoe, India, Clevergo, Wp.pt, Evite, Yandex,
GMail, Atlas, Hushmail, O2, Techemail, FastMail, Zapakmail, Virgilio, Abv or social portals like Ning, Hyves, Meinvz, Plurk, Xanga, Tagged, Mydogspace, Konnects, Bebo, Friendfeed, Plazes, Flickr, Cyworld, Last.fm, Mevio, Vkontakte, Skyrock, MySpace, Xuqa, Lovento, Faces, Plaxo, NetLog,
Facebook, Perfspot, Mycatspace, Livejournal, Famiva, Flixster, Xing, Multiply, Brazencareerist, Orkut, Bookcrossing,
Twitter, Koolro, Eons, Hi5, Fdcareer, Motortopia, Vimeo, Kincafe, Flingr, Friendster, Badoo. This contacts importer script is integrating with content management systems (aka CMS) like myBB, Dating Pro, JamRoom, Joomla, PHPMELODY, Boonex Dolphin, Vwebmail, Atmail5, PhpBB, phpFoX, SimpleMachines Forum (SMF), phpizabi, joovili, Joomla1.0, vBulletin, Drupal, jamit job, symfony, Buddy Zone, Wordpress, nowFire, Social Engine, PunBB, RoundCube.
Open Inviter is written in PHP 5 (no database required but cURL or wget required) and running on any webserver (tested on Apache) offering advanced tell a friend features. OpenInviterTM is a free self hosted solution that does not use a third party gateway (or API) to import contacts.
Installation it says:
Openinviter installation Guide.
Thank you for downloading The OpenInviter General Package. This document will guide you through the installation process.
A: Requirements:
Your server will need to have PHP5 installed with DOMDocument support and either cURL or WGET.
B: Install:
1. Extract the contents of the openinviter.tar.gz file you have just downloaded.
Note: tar -xzvf openinviter.tar.gz
2. Upload the extracted files to your webserver (subfolder is highly advised).
3. Run postinstall.php (http://yourdomain/openinviter_dir/postinstall.php)
You may encounter the following errors:
i) The cookie storing folder if not writable. (Change the cookie folder or modify it's permisions.)
ii) Php DOM extension is not installed. (Install dom extension for php)
iii) You don't have curl or wget installed. (Install curl or wget)
You may encounter the following warnings:
i) A plugin does not work properly. (Your server has either a firewall or there is a connectivity error)
Note: You have to fix all the errors or openinviter will probably not work.
Note*: You can't run postinstall.php again for 2 minutes.
4. Edit config.php to suit your needs.
5. Delete postinstall.php
6. Run example.php (http://yourdomain/openinviter_dir/example.php) and try to fetch your contacts.
Note: example.php is modifiable but keep in mind the structure of the file.
Also, its providing a PDF how to do it with PHP, excellent work has been done to respect KISS (keep it simple stupid!!).
Do you want users to be able to login/use your website using their google id? In that case, you can use OpenId, a standardized way to login (you'll be able to use other providers too). For more information about the implementation, look here (http://openid.net/developers/libraries/). This normally done on the server, so probably not with javascript.
I'm making a GWT project that uses PHP to connect to a DB2 database. When I compile the project and deploy it to the server (copy the contents of the WAR directory over), it works fine, obviously in hosted mode I run into the SOP issue since GWT is on port 8888 while the php script is running on port 80.
I'm trying to get the -noserver option to work but I must be missing something.. I went back and created the basic sample app from the command line (webApplicationCreator -out /home/mike/gwt/sample1)
I edited the build.xml to include the -noserver and -port 80 arguements for devmode. I want my app to be hosted at localhost/sample1 so I edited the -startupUrl to the whole URL I want to use: http://localhost/sample1/sample1.html
I compiled (ant), copied over the sample1.html, sample1.css from war to the webserver sample1 directory, and the (md5).gwt.rpc, clear.cache.gif, sample1.nocache.js and hosted.html files from the war/sample1 to sample1/sample1 directory as described in the GWT documentation (no history.html file was created).
I then run ant devmode from the project directory (/home/mike/gwt/sample1)
I can get to the sample1.html page, but when I click the button to send the name to the server it returns with
Remote Procedure Call - Failure
Server replies:
An error occurred while attempting to contact the server. Please check your network connection and try again.
I turned on firebug and it's returning a 404 for http://localhost/sample1/sample1/greet. This is where I'm stuck.. this file obviously doesn't exist on my webserver.. but why? Isn't this something that is supposed to be getting compiled by GWT?
Can anyone give me a hand? Thanks!
So, basically you've copied over the client-side of a client/server application. When your GWT client application attempts to make a Remote Procedure Call (RPC) to the server to a greeting service that is part of the initial sample, it can't find that service.
If you wanted to copy that service over, you'd need to have a Java application server, copy over the GreetingService, the web.xml that references it and possibly a few other things (I'd have to check in more detail). That doesn't sound like what you actually want, so either you'll want to build a GWT-RPC service in PHP that responds to that URL, or remove the reference in the GWT code to RPC call to the greeting service.
With a PHP back-end, you're probably not going to use GWT-RPC, I'm guessing that you're more likely to use JSON or XML, and if that's the case, then I'd go with removing the RPC call altogether for now.
Does this all make sense? Feel free to ask for further clarification.
To solve the SOP issue, I used the HttpProxyServlet to proxy the HTTP requests to my webserver through the development server.
Download httpProxyPackage.jar, copy it into WEB-INF/lib/, and configure it like so in WEB-INF/web.xml (this is for the StockWatcher tutorial, assuming your web root is the folder that contains the StockWatcher directory):
<servlet>
<servlet-name>jsonStockData</servlet-name>
<servlet-class>com.jsos.httpproxy.HttpProxyServlet</servlet-class>
<init-param>
<param-name>host</param-name>
<param-value>http://localhost/StockWatcher/war/stockPrices.php</param-value>
</init-param>
</servlet>
<servlet-mapping>
<servlet-name>jsonStockData</servlet-name>
<!--
http://127.0.0.1:8888/stockPrices.php in dev mode
http://gwt/StockWatcher/war/stockPrices.php in prod mode
-->
<url-pattern>/stockPrices.php</url-pattern>
</servlet-mapping>
Then redefine your JSON URL as:
GWT.getHostPageBaseURL() + "stockPrices.php?q=";
instead of:
GWT.getModuleBaseURL() + "stockPrices.php?q=";
It’s maybe not the best way, but if it can get someone else started… There was another way using php-cgi, but I didn’t have it installed.
i will create ftp account in plesk using php that ever user register in site can have an ftp account with his username and password .
i found many php api for cpanel but in plesk i can't find any thing ? can you help me ?
thank you so a lot before !
FTP user creation in Plesk Via SSH
http://ryanjbonnell.com/journal/ftp-account
I only run Plesk on CentOS, but there should be a similar directory on the Windows side. That being said, here's where I'd look - /usr/local/psa/admin/sbin. The filename I use is "ftpmng". Maybe search in the PSA directory for that. Here's what I get for help docs on that:
Usage: ftpmng [OPTIONS]...
--reconfigure-all
create configuration files for all domains
--reconfigure --vhost-name=<domain_name>
--set-disk-quota --vhost-name=<domain_name> --quota=<quota>
--get-disk-usage --vhost-name=<domain_name>
--update-user --user-name=<user_name>
--remove-user --user-name=<user_name>
--kill-proftpd-process --user-name=<user_name> --pid=<pid>
--features
returns PHP code which reflects state of several features support in ftpmng.
-h, --help
display this help and exit
please confirm what plesk version you used.
Normally, plesk provides the xml-rpc API for Developer, easily can create ftp and many others with php,java, c#.
http://download1.parallels.com/Plesk/PP10/10.4/Doc/en-US/online/plesk-api-rpc-guide/
http://download1.parallels.com/Plesk/PP10/10.4/Doc/en-US/online/plesk-api-rpc/