Sponsored Content
Top Forums UNIX for Dummies Questions & Answers transforming small javascript into perl Post 302190347 by marringi on Tuesday 29th of April 2008 10:52:48 AM
Old 04-29-2008
I see that this will be a bigger problem then I that, so I will figure a
way around this problem.

Thanks anyway
 

8 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

Help Required In Transforming A File

How will i convert a file <LREC><L:EPOCH>1198331268.553</L:EPOCH><LDATE>10-12-07</LDATE><L:SERVER>NONE</L:SERVER><L:PORT>NONE</L:PORT><LTIME>13:47:48.553</LTIME><LTEXT>dnvdmxk</LTEXT></LREC>... (3 Replies)
Discussion started by: anju
3 Replies

2. UNIX for Dummies Questions & Answers

onChange + javascript in perl CGI - question

Hello all, Am trying to include a onChange java script to my perl CGI application which uses POST method to upload files to file_server This is how I embedded javascript in the perl code that renders CGI application print qq| <script type="text/javascript" src="display.js"> </script>... (4 Replies)
Discussion started by: matrixmadhan
4 Replies

3. Shell Programming and Scripting

transforming records

Hi all In input file I have records like this: 0,1,0,87,0,0,"6,87","170,03",0,"43,5",0,0,0,0,"6,87","126,53" and in output file I need that these records transforms in : 0 1 0 87 0 0 6,87 170,03 0 43,5 0 0 0 0 6,87 126,53 Could you help me in this case? Please (13 Replies)
Discussion started by: shizik
13 Replies

4. UNIX for Advanced & Expert Users

Transforming psmf to ogv

Hi all. I would like to create a program that converts psmf file format (PSMF - MultimediaWiki) to ogv (Ogg - Wikipedia, the free encyclopedia). I know C++ and I worked with BMPs (so I can understand a simple file system like the BMP header is) but I didn't touch any kind of sound/video file... (1 Reply)
Discussion started by: lilezek
1 Replies

5. Shell Programming and Scripting

How to use JavaScript in Perl Object Oriented

i am new to Perl CGI Object oriented. I want to use some java script in my Perl CGI but i am not able to do that. I am using Submit button then via param() i am getting all field parameters. But i want to validate all fields first then i want to move. But Use of Java script, i don't know (1 Reply)
Discussion started by: Navrattan Bansa
1 Replies

6. Shell Programming and Scripting

How to call perl web service from javascript?

Hi, I would like to call the below perl web service from javascript .Any help would be appreciated.I am new to web services.Please do the needful. Server Program(Perl Web Service) #!/usr/bin/perl use lib '/usr/lib/perl5/5.8.8/SOAP-Lite-0.65_3/lib'; use SOAP::Transport::HTTP; use Demo;... (3 Replies)
Discussion started by: liyakathali
3 Replies

7. Programming

Transforming data to other format

Dear All I would like to transform data from one format to another format. my Input: 0 0 1 0 1 0.308 0 2 0.554 0 3 0.287 output: Z (0,0)= 1 Z (0,1)=0.308 Z (0,2)=0.554 Z (0,3)=0.287 (2 Replies)
Discussion started by: bala06
2 Replies

8. UNIX for Dummies Questions & Answers

Transforming data so it looks like the one you specified

Lets say for instance I have this data within a file named transform xxx#yyy@zzz and I want it to be in the format ofZZZ xxx-yyy How do I go about doing this? (3 Replies)
Discussion started by: l3monz
3 Replies
OpenGuides::JSON(3pm)					User Contributed Perl Documentation				     OpenGuides::JSON(3pm)

       emit_json
	   Renders the given node as JSON

       output_as_json
	   Renders the given arbitary data as JSON

NAME
OpenGuides::JSON - An OpenGuides plugin to output JSON. DESCRIPTION
Does all the JSON stuff for OpenGuides. Distributed and installed as part of the OpenGuides project, not intended for independent installation. This documentation is probably only useful to OpenGuides developers. SYNOPSIS
use Wiki::Toolkit; use OpenGuides::Config; use OpenGuides::JSON; my $wiki = Wiki::Toolkit->new( ... ); my $config = OpenGuides::Config->new( file => "wiki.conf" ); my $json_writer = OpenGuides::JSON->new( wiki => $wiki, config => $config ); # JSON version of a node. print "Content-Type: application/javascript "; print $json_writer->emit_json( node => "Masala Zone, N1 0NU" ); # Ten most recent changes. print "Content-Type: application/javascript "; print "Last-Modified: " . $self->json_timestamp( items => 10 ) . " "; print $json_writer->make_recentchanges_json( items => 10 ); METHODS
new my $json_writer = OpenGuides::JSON->new( wiki => $wiki, config => $config ); "wiki" must be a Wiki::Toolkit object and "config" must be an OpenGuides::Config object. Both arguments mandatory. emit_json $wiki->write_node( "Masala Zone, N1 0NU", "Quick and tasty Indian food", $checksum, { comment => "New page", username => "Kake", locale => "Islington" } ); print "Content-Type: application/javascript "; print $json_writer->emit_json( node => "Masala Zone, N1 0NU" ); Note: Some of the fields emitted by the JSON generator are taken from the node metadata. The form of this metadata is not mandated by Wiki::Toolkit. Your wiki application should make sure to store some or all of the following metadata when calling "write_node": postcode - The postcode or zip code of the place discussed by the node. Defaults to the empty string. city - The name of the city that the node is in. If not supplied, then the value of "default_city" in the config object supplied to "new", if available, otherwise the empty string. country - The name of the country that the node is in. If not supplied, then the value of "default_country" in the config object supplied to "new" will be used, if available, otherwise the empty string. username - An identifier for the person who made the latest edit to the node. This person will be listed as a contributor (Dublin Core). Defaults to empty string. locale - The value of this can be a scalar or an arrayref, since some places have a plausible claim to being in more than one locale. Each of these is put in as a "Neighbourhood" attribute. phone - Only one number supported at the moment. No validation. website - No validation. opening_hours_text - A freeform text field. json_maker Returns a raw Wiki::Toolkit::Plugin::JSON object created with the values you invoked this module with. make_recentchanges_json # Ten most recent changes. print "Content-Type: application/javascript "; print "Last-Modified: " . $json_writer->json_timestamp( items => 10 ) . " "; print $json_writer->make_recentchanges_json( items => 10 ); # All the changes made by bob in the past week, ignoring minor edits. my %args = ( days => 7, ignore_minor_edits => 1, filter_on_metadata => { username => "bob" }, ); print "Content-Type: application/javascript "; print "Last-Modified: " . $json_writer->json_timestamp( %args ) . " "; print $json_writer->make_recentchanges_json( %args ); json_timestamp print "Last-Modified: " . $json_writer->json_timestamp( %args ) . " "; Returns the timestamp of the RSS feed in POSIX::strftime style ("Tue, 29 Feb 2000 12:34:56 GMT"), which is equivalent to the timestamp of the most recent item in the feed. Takes the same arguments as make_recentchanges_json(). You will most likely need this to print a Last-Modified HTTP header so user-agents can determine whether they need to reload the feed or not. SEE ALSO
o Wiki::Toolkit o <http://openguides.org/> o <http://chefmoz.org/> AUTHOR
The OpenGuides Project (openguides-dev@openguides.org) COPYRIGHT
Copyright (C) 2003-2009 The OpenGuides Project. All Rights Reserved. This module is free software; you can redistribute it and/or modify it under the same terms as Perl itself. CREDITS
Code in this module is mostly pirated from OpenGuides::RDF, those authors deserve all the credit. Chris Prather did the pirating. perl v5.14.2 2013-01-11 OpenGuides::JSON(3pm)
All times are GMT -4. The time now is 04:59 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy