function object=jgbrowser(x)
if nargin==0
  [s,object]=unix('/home/data1/www/optserver/matlab/bs geturl');
else
  [s,object]=unix('/home/data1/www/optserver/matlab/bs echonext');
end

object=object(1:length(object)-1);

if findstr(object,'http:') ~= 1
  object='';
  return;
end
object=object(6:length(object));
i=findstr(object,'/jg/serv/');
if i==0
  object='';
  return;
end
object=[object(1:i-1),object(i+8:length(object))];
i=findstr(object,'.html');
if i==0
  object='';
  return;
end
object=[object(1:i-1),object(i+6:length(object))];
i=findstr(object,'?');
if i>0
  object(i)='(';
  object=[object,')'];
end
return
