[wixet] r389 committed - [No log message]

1 view
Skip to first unread message

wi...@googlecode.com

unread,
Sep 23, 2010, 7:44:08 AM9/23/10
to wi...@googlegroups.com
Revision: 389
Author: maxpowel
Date: Thu Sep 23 04:43:09 2010
Log: [No log message]
http://code.google.com/p/wixet/source/detail?r=389

Modified:
/trunk/apps/core/modules/account/actions/actions.class.php

=======================================
--- /trunk/apps/core/modules/account/actions/actions.class.php Wed Sep 22
17:35:22 2010
+++ /trunk/apps/core/modules/account/actions/actions.class.php Thu Sep 23
04:43:09 2010
@@ -29,6 +29,8 @@
return sfView::NONE;
}
public function executeValidateAccount(sfWebRequest $request){
+ $languages = $this->getRequest()->getLanguages();
+ $this->getUser()->setCulture($languages[0]);
$validation =
Doctrine::getTable("AccountValidation")->findByHash($request->getParameter("hash"))->getFirst();
if($validation){
$username = strtolower(trim(str_replace(" ", "",
$validation->getFirstname().".".$validation->getLastname())));
@@ -46,13 +48,15 @@
$this->email = $validation->getEmail();
$this->hash = $validation->getHash();
$this->username = $i == 1?$username:$newUsername;
-
- $ch = curl_init();
- curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
- $url="http://api.wipmania.com/".$_SERVER['REMOTE_ADDR'];
- curl_setopt($ch, CURLOPT_URL,$url);
- $code = curl_exec ($ch);
- echo $res;
+ //Get the country
+ $ch = curl_init();
+ curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
+ $url="http://api.wipmania.com/".$_SERVER['REMOTE_ADDR'];
+ curl_setopt($ch, CURLOPT_URL,$url);
+ $res = curl_exec ($ch);
+
+ $this->country =
Doctrine::getTable("country")->findByCode($res)->getFirst();
+ //

}
else

Reply all
Reply to author
Forward
0 new messages