Embed not working with google analytics api - laravel

In the laravel project I'm using google api that fetches google analytics report when user logins with his google analytics a/c. But when I try to give embed functionality where user can use it in his websites to show fragments like current online users, country-specific users,etc. It isn't working due to some issues.
simple embed code that user is supposed to fetch data anywhere outside my website:
<embed src="http://www.example.com/shareEmbed/id">
while I'm testing and pasting the above code in different page, it shows login error as in below image
please help me!

Related

Generate Google Photo link from Google Picasa Web API data call

I am currently trying to generate a url to link to a public Google Photos gallery. I am aware from some research that all calls regarding Google Photos go through the Picasa API. So, by running file_get_contents on the following URL, I have retrieved a full listing of all public albums on my user account
http://picasaweb.google.com/data/feed/api/user/<USERNAME>?alt=json&kind=album&hl=en_US
This works perfectly and includes links to the gallery in Picasa. However, I would much prefer to be able to generate a link to the corresponding Google Photos gallery. On sharing Google photos, a shortened url is generated, like
https://goo.gl/photos/code
I was wondering if there was any possible way, given the album ID from the API call that such a link could be generated
Previous questions on this subject haven't generated much response unfortunately - is anyone aware of any such Google link generation capability?

Gem to post message on google plus?

Is there any gem to post message on google plus from our rails application ?. I want to post a meesage on my google plus page whenever i logged in my application using google plus credentials. Please suggest me the gem name to do this. Thanks in advance.
EDIT
I have a app in goole plus. On behalf of my application users, my app should post messages.
I suggest to use gem 'google_plus'`
As Google plus having so many restrictions. Still I would Like to Share a link you can follow that..
How to share content from our site to google plus
For more reference:
https://developers.google.com/accounts/docs/OAuth2
https://developers.google.com/+/web/share/interactive#button_attr_calltoactionurl
I hope it will work fine...
Yes, there's a Ruby client library provided by Google which allows you consume their Google+ API
https://developers.google.com/api-client-library/ruby/apis/plus/v1
UPDATE
The URL above points to Ruby client library. The API you're looking for is moments.insert
https://developers.google.com/+/api/latest/moments/insert
There is an official Google API Client gem. However the Google+ API does not allow standard automated posting to a profile. The recommended approach to share posts is the share button or the interactive share API.
The automated posting that Google+ does support are:
App activities/moments are a way to make actions within your app visible to other users of your app. They do not appear in the Google+ posts stream.
Domains API can be used with Google Apps accounts to create posts that are limited to users within the company.
Pages API can be used to post to a page (not a profile) but is limited to approved partners.

Add user review to Google map from my application(Android)

I am trying to create a location-based services Android application. I had successfully getting the user reviews from Google Places API by following the guidance from this link.
https://developers.google.com/places/documentation/details
I also found many posts regarding how to get user reviews from Google Places. But Now I want to create a function which user can insert reviews from my application. Is there anyway to do that?
Thanks.
No. There is no API for writing review. Also the Google+ mobile URL doesn't have the write review option from last year. Its a bug , but Google is not fixing this.
There is only one way to write review is through desktop URL. I have a similar location base app in play store where I have done some workaround to show desktop site to write review.

Want to share image via google+ api

This is my code
<button
class="g-interactivepost"
data-contenturl="http://www.pubandbar-network.co.uk/nightlife_pubs-bars.html"
data-clientid="102180630313-ef89c6gjgahgitf0s9qknhrl5mo351ga.apps.googleusercontent.com"
data-prefilltext="Engage your users today, create a Google+ page for your business."
data-calltoactionurl="http://www.pubandbar-network.co.uk/nightlife_pubs-bars.html"
data-cookiepolicy="single_host_origin"> Share
</button>
I want to share image with this. Please help me how can I share image via google+ API.
My second question is :
Is there any way in php to share on google+ automatically?
The images that appear in shares are calculated by Google based on the schema data on your page. As an example, you can use the snippet configuration tool to configure the image and description for your share. When you set the content-url to point to the page with schema, Google will use that schema microdata to set the image and so forth.
You cannot share programmatically to Google+ except with Google+ App Activities.

Using Google Analytics on a jQuery Mobile app that runs entirely off the phone

I have made an app using jQuery mobile and phoneGap, and read its good to put Google Analytics on there. I just a little confused because most of the app (pages etc... ) runs from the index.html file on the phone. The only time the app communicates with the server is when it logs a user in and they do ajax requests to retrieve or put data to a database.
Can I still use the analytics package here? Or is the whole point of it to be used with an app where all the DOM etc is stored online?
Thanks
You can probably use the event tracking feature of Google Analytics to help you out here:
https://developers.google.com/analytics/devguides/collection/gajs/eventTrackerGuide
You basically just fire a js function and pass in descriptive strings and category I think for each of the interactions you want to track / report on:
_trackEvent(category, action, opt_label, opt_value, opt_noninteraction)
Hope that helps

Resources