I use the wiktionary api to get information from wiktionary.org ..
I get the data in json format and I can parse it too ...
but I want to remove part of the result from the result (in fact, I only need some data), but I do not know how to remove certain content from the result.
The code I use is
<script type="text/javascript" src="./jquery-1.4.3.min.js"></script>
<div id="wikiInfo"> contents</div>
<script type="text/javascript">
$.getJSON('http://en.wiktionary.org/w/api.php?action=parse&page=acting&format=json&prop=text&callback=?',
function(json) {
$('#wikiInfo').html(json.parse.text.*);
$("#wikiInfo").find("a:not(.references a)").attr("href", function(){
return "http://sample.com/" + $(this).attr("href");});
$("#wikiInfo").find("a").attr("target", "_blank"); }
);
</script>
the above code displays the data as on the next page.
http://englishore.com/parse-wiki.php
But I need to cancel the "Pronunciation and translation" part of the result.
How can i do this?
source
share