Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Symbol resolve failed all the time... #5

Open
pottertech opened this issue Apr 20, 2020 · 0 comments
Open

Symbol resolve failed all the time... #5

pottertech opened this issue Apr 20, 2020 · 0 comments

Comments

@pottertech
Copy link

I started with "https://github.com/shaqarava/TradingView-UDF" as my base because I need the UDF to be in PHP. I always get "Symbol resolve failed:

"COINBASEPRO:BTC/USD, reason: invalid symbol" message and no chart. I have no idea what I am doing wrong at this point.

My web page can be reached at "http://94.237.73.33/chart-example.html" and the code is as follows:

<title>PHP TradingView UDF Example</title> <script type="text/javascript" src="chart/charting_library/charting_library.min.js"></script> <script type="text/javascript" src="chart/datafeeds/udf/dist/polyfills.js"></script> <script type="text/javascript" src="chart/datafeeds/udf/dist/bundle.js"></script> <script type="text/javascript">

function getParameterByName(name) {
name = name.replace(/[[]/, "\[").replace(/[]]/, "\]");
var regex = new RegExp("[\?&]" + name + "=([^&#]*)"),
results = regex.exec(location.search);
return results === null ? "" : decodeURIComponent(results[1].replace(/+/g, " "));
}

function initOnReady() {
var widget = window.tvWidget = new TradingView.widget({
fullscreen: true,
symbol: 'BTC/USD',
interval: 'D',
container_id: "tv_chart_container",
debug: true,
datafeed: new Datafeeds.UDFCompatibleDatafeed("http://94.237.73.33/api"),
library_path: "chart/charting_library/",
locale: getParameterByName('lang') || "en",
disabled_features: ["header_saveload","use_localstorage_for_settings"],
enabled_features: [],
charts_storage_url:"",
charts_storage_api_version: "1.1",
client_id: '',
user_id: '',
theme: getParameterByName('theme'),
});
};

window.addEventListener('DOMContentLoaded', initOnReady, false);
</script>

*** Console logs
Symbol resolve requested: BTC/USD library.4876b44fcf466b634068.js:186:2100
Event "panes_order_changed", arguments: [] library.4876b44fcf466b634068.js:568:283
Symbol resolve failed: BTC/USD, reason: invalid symbol library.4876b44fcf466b634068.js:186:2100
Event "series_properties_changed", arguments: ["lQwFlf"] library.4876b44fcf466b634068.js:568:283```

Symbol

BTC/USD on COINBASEPRO exchange

Any help is greatly appreciated.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant