Lines Matching refs:cid

25     $this->summaryURL  = 'https://pubchem.ncbi.nlm.nih.gov/summary/summary.cgi?cid=';

26 $this->downloadURL = 'https://pubchem.ncbi.nlm.nih.gov/image/imgsrv.fcgi?t=%s&cid=%s';
51 list($cmd,$cid) = $match;
53 if(strpos($cid,'|')!==false){
54 list($cid,$title)=explode('|',$cid);
70 if(!$cid){
76 if (!is_numeric($cid)){
77 $renderer->doc .= sprintf($this->getLang('pubchem_invalid_cid'),$cid);
80 if ($this->propCache->Exists($cid)){
81 $ext_props = json_decode($this->propCache->GetMediaText($cid),true);
83 $ext_props = $this->getProperties($cid);
92 $renderer->doc .= 'href="'.$this->summaryURL.$cid.'" title="Go to PubChem site" class="pubchem_link">'.$cid.'</a>'.NL;
95 $xml = $this->getPubchemXml($cid);
113 $id = $cid.$mode;
116 $url = sprintf($this->downloadURL,$mode,$cid);
120 if (empty($pubchem_cache[$cid]['iupac'])){
121 $this->getProperties($cid);
125 $this->_name_row($renderer,$cid,$iupac,$title);
131 $renderer->doc .= $this->getImageHtml($cid,$mode);
134 $renderer->doc .= $this->getImageHtml($cid,$mode);
146 function getImageHtml($cid,$mode){
147 $tag = '<div class="pubchem_imgbox"><a href="'.$this->summaryURL.$cid.'" target=_blank>';
148 $tag .= '<img src = "'.$this->imgCache->GetMediaLink($cid.$mode).'" class="media" ';
149 $tag .= 'alt="PubChem image '.$cid.'" ';
150 $tag .= 'title="CID:'.$cid.' Click to PubChem page"/></a></div>';
156 * @param string $cid
159 function getProperties($cid){
160 $xml = $this->getPubchemXml($cid);
202 $this->propCache->PutMediaText($cid,json_encode($ext_props));
208 function getPubchemXml($cid){
210 $xml = $this->ncbi->GetPubchemXml($cid);
212 $filepath = $this->xmlCache->GetMediaPath($cid);
232 * @param string $cid
236 function _name_row(&$renderer,$cid,$iupac='',$title=''){
242 $renderer->doc.=($title!='')?$title:$cid;