Ask is moving to Stack Overflow and! Please use the "opendaylight" tag on either of these sites. This site is now in Read-Only mode


how to implement postman (javascript:ajax)generated code to a webpage

asked 2016-04-24 20:26:35 -0700

luis999 gravatar image

updated 2016-04-24 20:32:19 -0700


i have create a custom topology in mininet and have install opendaylight(lithium). on my opendaylight, i have install 'old-dlux-all' and 'odl-l2switch-switch-ui'.

i am trying to create a webpage that able to run api. i have use postman to generated code(javascript:ajax) but i don know how to implement the code to a web page

i have create a simple api web(get topology) to test out.

image description

image description

my question are
1)how do i implement postman generated code(javascript:ajax) to a webpage?
2)how do i show the output on my webpage?

many thanks in advance. :)

edit retag flag offensive close merge delete

1 answer

Sort by ยป oldest newest most voted

answered 2016-04-26 05:53:32 -0700

karthik330 gravatar image

updated 2016-04-26 06:15:10 -0700

This is just a rest call right? .So I will give you hint . Create a Rest Client in JavaScript or AngularJS or JQuery (code is almost similar to what you mentioned). It will be useful to display the data whatever you returned from the server(here topology details) to your webpage. You have to add authentication details too. Try it . If you still face problem, let me know !

Thanks, -Karthik

edit flag offensive delete publish link more


thank you. I change the restconf code from javascript(ajax) to php(curl) and set up a wamp server. Now it able to run restconf code.

luis999 ( 2016-04-26 17:27:12 -0700 )edit

Nice ..Now a days AngularJS is powerful where you can do all the stuffs in client side itself. If we go for php, we need server and all. If you want to design only FrontEnd better go for JavaScript / Angular!. It wont take much time to learn.Anyway go ahead whichever is comfortable to you..Thanks

karthik330 ( 2016-04-26 21:02:53 -0700 )edit

thank you, will try up AngularJS.

luis999 ( 2016-04-27 22:15:37 -0700 )edit
Login/Signup to Answer

Question Tools

1 follower


Asked: 2016-04-24 20:26:35 -0700

Seen: 1,010 times

Last updated: Apr 26 '16