Caution: Translations of Quran and Ḥadīth may lead to possible misapplications and misinterpretations. This site is intended for students of sacred knowledge that are proficient in comprehending classical Arabic and have a strong foundation in Islamic sciences. Also note that religious injunctions rely on several aspects beyond what one may glean through reading individual aḥādīth.
bayhaqi:2876Abū ʿAbdullāh al-Ḥāfiẓ And ʾAbū Saʿīd b. Abū ʿAmr Waʾabū ʿUthmān Saʿīd b. Muḥammad b. Muḥammad b. ʿAbdān > Abū al-ʿAbbās Muḥammad b. Yaʿqūb > Aḥmad b. ʿAbd al-Jabbār al-ʿUṭāridī > Ḥafṣ b. Ghiyāth > ʿUthmān b. Ḥakīm > ʿIkrimah > Ibn ʿAbbās

[Machine] Prayer is not appropriate for anyone except the Prophet. The Sheikh means by this the prayer that is a greeting to his remembrance with great respect. As for his prayer for others, it was in the sense of supplication and blessing, and that is permissible for others.  

البيهقي:٢٨٧٦أَخْبَرَنَا أَبُو عَبْدِ اللهِ الْحَافِظُ وَأَبُو سَعِيدِ بْنُ أَبِي عَمْرٍو وَأَبُو عُثْمَانَ سَعِيدُ بْنُ مُحَمَّدِ بْنِ مُحَمَّدِ بْنِ عَبْدَانَ قَالُوا ثنا أَبُو الْعَبَّاسِ مُحَمَّدُ بْنُ يَعْقُوبَ ثنا أَحْمَدُ بْنُ عَبْدِ الْجَبَّارِ الْعُطَارِدِيُّ ثنا حَفْصُ بْنُ غِيَاثٍ عَنْ عُثْمَانَ بْنِ حَكِيمٍ عَنْ عِكْرِمَةَ عَنِ ابْنِ عَبَّاسٍ قَالَ

مَا يَنْبَغِي الصَّلَاةُ مِنْ أَحَدٍ عَلَى أَحَدٍ إِلَّا عَلَى النَّبِيِّ ﷺ قَالَ الشَّيْخُ يُرِيدُ بِهِ الصَّلَاةَ الَّتِي هِيَ تَحِيَّةٌ لَذِكْرِهِ عَلَى وَجْهِ التَّعْظِيمِ فَأَمَّا صَلَاتُهُ عَلَى غَيْرِهِ فَإِنَّهَا كَانَتْ بِمَعْنَى الدُّعَاءِ وَالتَّبْرِيكِ وَتِلْكَ جَائِزَةٌ عَلَى غَيْرِهِ