GlobalQuran / site

Complete Quran Site Code developed with GlobalQuran api in javascript. you can use it anywhere, on desktop or just upload on any site with your own layouts.
http://GlobalQuran.com
116 stars 66 forks source link

Having problems starting audio. #43

Open alexanderjhs opened 6 years ago

alexanderjhs commented 6 years ago

I cannot start the API from PHP If I place jquery and all the other scripts in the end of my body html. So It has to be above the php script for audio/quran to work. Do you know what causes this problem?

iBasit commented 6 years ago

Can you post your code here please.

alexanderjhs commented 6 years ago

<?php include 'app.settings.php'; ?>

<!doctype html>

Skien Moske

Quran

$value) { if (is_array($value)) { foreach ($value as $key2 => $value2) { $urlstring .= $key . '[' . $key2 . ']=' . $value2 . '&'; } } else $urlstring .= "$key=$value&"; } } ?>

alexanderjhs commented 6 years ago

This is my code. I did a shortcut on it. And It was to display the Quran in another page without jQuery and so on. Looks like that this API doesn't work well with jQuery. Tried to modify jQuery, and tried to modify this API aswell. But nothing seemed to work :) Sorry for late answer, did not see that you had commented.

iBasit commented 6 years ago

There might be a conflict between jQuery versions and legacy code. The complete application is based on jQuery jQuery v1.11.1 — if you want to use latest jQuery, then you would have to update few functions, which they have removed, but I would recommend to use old jQuery, unless you are doing something really new which old does not support.

ATouhou commented 6 years ago

I think the confusion is somewhere else. Can you please explain your problem exactly with screenshots and add the code to gists or something with proper formating Alexander :-)

alexanderjhs commented 6 years ago

skjermbilde1 skjermbilde2 skjermbilde3 skjermbilde4

alexanderjhs commented 6 years ago

The top bar supposed to be like that last image. But everything changes with the jquery when I put the php in there. Tried to do some tricks with CSS to fix all the wrongness in there, but still I do not feel comfortable

ATouhou commented 6 years ago

I don't exactly understand your question, but I don't think it is related to the API, but something fundamental about HTML/JavaScript.

You want the audio player in a fixed top location unless the person is on a certain place on the screen?

iBasit commented 6 years ago

It's a CSS issue.

There are two ways to solve this.

  1. Use Iframe to display Quran directly from GlobalQuran.com
  2. remove GlobalQuran CSS and add your own CSS (better to make modifications on GlobalQuran CSS)
alexanderjhs commented 6 years ago

ATouhou Thanks for tip.

And iBasit thanks very much for the tips. I could use iframe but I want the site to be more proffesional. You know what, I havent thought of removing CSS Thanks again :)