Did anyone here manage to curl in aweber?
Thanks!
yeah, however its useless, as after some form submissions they will block your account because email subscriptions etc need to come from the client ip and not a fixed site ip. What are you trying to do exactly?
Aweber provides an API https://labs.aweber.com/ which you can use to add subscribers etc, most likely what you were doing with the curl I assume.
Plus it wont get your IP blocked!
Related
I need to push offline transactions to Google Analytics.
I am thinking of creating a php script that queries the ecommerce database looking at transactions made in the last hour created from the backend. Having identified these transactions (and line items/SKU's).
How do I use PHP to push data to Google Analytics?
You need to go though the measurement protocol. There is no client library to help you do this in PHP you will have to code it yourself. That being said its not that hard its just a normal HTTP Post or HTTP Get request. The trick is building up your requests correctly.
A couple of quick tips.
Qt stands for que time and will allow you to set the time that the hit arrived on your server. Note it must not be greater than four hours ago.
While you are testing this you can use the debug endpoint to validate your hits. The hits wont be sent to Google but it will tell you if they are valid or not.
Measurement Protocols as #DaImTo mentioned is the answer. make a try here replacing the UA Id -
https://ga-dev-tools.appspot.com/hit-builder/?v=1&tid=UA-XXXXX-Y&cid=555&t=transaction&ti=12345&ta=westernWear&tr=50.00&ts=32.00&tt=12.00&cu=EUR
You can use DIv tool to validate all your post requests.
(dont forget to enable - ecommerce from view settings in GA when testing on new account)
I want to get post data only from specific url(s), when someone post to my page some data from unwanted url, my page should not let the data pass. I couldn't find any example or documentation about this control or i'm asking wrong question to google, maybe it is simple but i have never needed such control.
E.g i want to let only paypal to send post data to my page. Hope you can help me. Thanks in advance.
Data is never sent to you by a "domain". I.e., neither "Paypal" nor paypal.com are sending you POST requests; some computer is sending you POST requests. That computer may or may not be under the control of Paypal the company, serve the website paypal.com or be within a network that belongs to Paypal (company or website).
Obviously you cannot programmatically figure out whether the server legally belongs to Paypal the company.
You can figure out what IP address paypal.com has and compare that to the IP address that's sending you POST requests, but this doesn't have to mean anything since Paypal has hundreds or thousands of servers, and the servers that serve paypal.com the website are likely not the same that are working on the backend to handle transactions.
You need to establish some form of trust between Paypal and yourself some other way. Either Paypal will promise to only ever send requests from one specific IP address, which you can check against. Or they promise to send a secret authentication with the request, which only you and Paypal know. Or you'll agree to use SSL client certificates to establish mutual trust. Or Paypal sends some transaction id which only it could know about which you can validate against.
You can use $_SERVER['HTTP_REFERER'] to check which page the data is passed from
Come secret key (only your page can generate) can be passed along with the form
Use a captcha image/ generate a session variable from the form page
I am wondering whether i can add google analytic to an email.
I want to check my click rate , open rate of my sent mail. I have done some research on this and I learnt that there is a track code should be useful.
So,
Since now i am sending an html version email, is it possible to add the code into the mail?
Also,
If i want to see the result of it , is it possible i do not need to login to the google page, but connect to their server and retrieve the result and show them on my php page?
Thank you
I would say NO on this question. You could of course add the Google Analytics script-snippet to your HTML email, but I believe most e-mail clients will block the JavaScript for security reasons. Thus leaving you with inaccurate data, at best.
In your case, if you don't want to send your mails through MailChimp or some other third party service that does the tracking for you (they track both openings and clicks), I would implement my own "simple" tracking system. Each link in the email re-directs through a page that you are in control of, where you track the click and then redirect the user to the appropriate address.
Update
About getting data from your Google Analytics account, I believe you can use the Analytics Reporting API. Haven't tried it myself, but it sounds like what you are needing.
Yes , when you are sending the HTML code to the client , enclose an analytics snippet in the FOOTER of your page. That should do it. However you cannot modify the code.
You can use Google Analytics tracking code, but you will see the "visits" only.
"Visits" => When a user opens an email of you (and of course to be connected to internet)
I think this code will not work inside Outlook.
To see the results, you need to login into your Google Analytics account.
PS: Be sure to setup a valid analytics tracking code.
You can only track link-clicks with Google Analytics if your target site has the Analytics Code in it:
You can read about it here:
http://analytics.blogspot.com/2009/03/tips-for-tracking-email-marketing.html
Yes it is possible to use google analytic's to track open rates.
If you have a pure text version of a email no it is not possible to track it as it need a call to a image so it is only possible using a html version. No you do not try and embed the standard javascript for the tracking you make a direct call to the tracking gif.
There was a free service that did do this
http://web.archive.org/web/20100828084217/http://email-tracking-with-google-analytics.com/index.php
Is it possible to create a gmail gadget with a button that would send a message's sender, subject, date and content via POST to some PHP page?
If so, any clues as to how this could be done?
I have been asked to integrate this as part of a small CRM, not sure if it can be done.
Thanks!
Contextual Gadgets might cover what you need, alternatively you could fetch the messages externally using the Mail feeds.
In either case, you will need to be authorised either via the Google Apps Marketplace or directly from the domain administrator by setting up OAuth credentials.
It's highly unlikely; the emails are considered private, no gadget should have access to them.
i need an sms service that can gives me a phone number and then my customers can send me sms to that number. then posts the sms information to my website like http://xx.com/newsms.php?body=hey
Thanks
Twilio recently released a SMS API. With Twilio you can:
Get a unique phone number (not a keyword at a shared short code).
Easily connect it via a HTTP POST
It's ridiculously simple. Check out the API.
Try www.textmarks.com - they got a PHP API as well.
If the content can be public or semi-public you might consider using Twitter, which allows various ways of posting via SMS. Their API lets you do pretty much whatever you want with the resulting feed.
An upside of this could mean extra exposure for your site, depending on how you implement it. This is especially true if any of your customers happen to be heavy Twitter users. Also, people would be not be limited to SMS, but could post via web or twitter apps.