Retrieving images from eBay's gallery using eBay API - arrays

So I'm very new to developing with eBay's API (or any API) and can't seem to work out how to reference the images from the gallery in the listing template. I don't want to use the URL specifically but rather use the eBay API to bring the images in from the eBay gallery so you don’t have to upload the images twice.
From What I understand, this can be done through an array using Item.PictureDetails.PictureURL. But I could be wrong.
Anyone done/know how to do this? Any help would be awesome!

I'm using PHP with XML.
So, if i understand your problem, you must call GetItem API (http://developer.ebay.com/devzone/xml/docs/reference/ebay/GetItem.html) to retrieve the data for a single item.
This call return an xml where you can find picture URL.

Related

How to fetch text file from google drive with json contents React Native

I need to access a simple text file from my google drive in React Native.
I saw in this post about how you can use this link structure to get a photo from google drive: https://drive.google.com/uc?export=view&id=YOUR PHOTO ID. Is there a structure like this to get a text document?
People keep telling me to setup a backend using sqlite or something but it seems so overkill for the very little that I need. I don't need to set data I just need to read it from a URL. Also, I tried doing a backend but from my limited knowledge, I can't use a backend server on iOS.
Any Ideas?

2sxc - Getting URL path from DNN link parameter / Tab ID

I am working on integrating a 2sxc content WebAPI feed into a ReactJS application.
I have managed to get a JSON feed of data into the application, and am in the process of mapping out the data.
I'm wondering what the best practice would be to "resolve" a URL which is coming through as a DNN Page/ Tab ID.
Below I will showcase the various points this is referenced...
First the Setup of the entity / data types...
Then this is an example entry with the data filled out... The page link / URL is set up to point to another internal page on the DNN website:
Finally you can see this data item come through as a JSON feed via the 2sxc API:
What is the best way to convert this piece of data into a URL which can be used in a SPA type application?
There isn't any "server-side" code going on, just reading a JSON feed on the client side...
My initial idea would be to parse this piece of data in JS, to extract the number then use something like this:
http://www.dotnetnuke.com/tabid/85/default.aspx
http://www.dotnetnuke.com/default.aspx?tabid=85
I was hoping someone with more experience would be able to suggest a better / cleaner approach.
Thanks in advance
If you were server-side in Razor you'd be doing something like this:
#using DotNetNuke.Common
View List
XXXX = Dnn.Tab.TabID or define a string with the tab id you want
I seem to have a vague memory that I saw somewhere that Daniel (2sxc) has a way to use Globals.NavigateUrl() or similar on the client side, but I have no idea where or if I did see that.
The Default.aspx?tabid=xx format will certainly work, as it's the oldest DNN convention and is still used in fallbacks. The urls aren't nice, but it's ok.
The reason you're seeing this is because the query doesn't perform the automatic lookup with the AsDynamic(...) does for you. There is an endpoint to look them up, but they are not official, so they could change and therefor I don't want to suggest that you use them.
So if you really want a nicer url, you should either see if DNN has a REST API for this, or you could create a small own 2sxc-api endpoint (in the api folder) just to look that up, then using the NavigateURL. Would be cool if you shared your work.

Display a doc/docx with AngularJS and Mongoose

I store word doc/docx as binary data file in mongoDB (not GridFS) and I would like to display it in my AngularJS client.
I probably should use Google Docs Viewer but what I would like to know is how how should mongoose send the file and how AngularJS should use the object it received to display it.
There aren'y currently any projects out there that allow you to render doc/docx in a browser (that I know of).
Your best bet would be to convert the document to HTML or a PDF before you store it in MongoDB (Apache Tika https://tika.apache.org/ can help with this).
If you are using HTML you can then render that easily enough, if you went for PDF take a look at PDF.js - https://mozilla.github.io/pdf.js/

How to consume Spring Data Rest Webservices API with AngularJS

i had been working in a Spring Rest Data API in an application (just for fun).
I have the core made, works fine but now I want to use AngularJS as front-end.
I had work with Jackson (Mapping Java Objects to JSON), but with Spring Rest Data the Json response it's diferent, it has _embedded, _links, self, etc. links that make me confuse. I have something like this in the root url http://localhost/8080/app/api/tarifas
I have used a JS script called restangular but i have serveral problems (I'm newbie with Angular)
In my controller i have this
Check the error
If I add a RestangularProvider in my app.config(...) and change the Controller to getList instead get, works fine, but I need several entities data formats.
Any help it's welcome. If you know a better way please tell me.
Thanks!!
UPDATE
I found a form to do this (i don´t know if it's the better) but now my problem is the next:
I have objects that has other objects as attributes (realtionship), and the reference in the JSON is a link (not an object). Then, in the grid; the value of the description's internal object is blank. To get the json data I found this
Now I have the next content for one register (one of the grid)
And my grid (In Angular, HTML) looks like this (empty fields)
How can I retrieve the attribute description from the member estado, categoria, etc. and show it in the grid. Should make the request to get it?
Thanks!!
You can use either angular.toJson or json.stringify
Angular-toJson documentation
Json.stringify documentation

Retrieve Response data from another website using cakephp

I am trying to hit the courier companies website from Controller ( e.g bluedart,fedex etc) by passing the courier tracking number and fetch status of the given tracking number.
I am using $HttpSocket->get/post to hit the webpage URL
I am able to display the response body
How can I fetch the data from the response.
Or is there any other way to achieve the same
Please help me out .
How can I fetch the data from the response.
Parse the result, either using regular expressions or the DOMDocument class and traverse it. See Parsing HTML in Cakephp as well.
Or is there any other way to achieve the same
Use the APIs these companies usually offer.

Resources